View on GitHub

os202

OS202


Home

Top 10 List Week 04:

1.Memory Address
A memory address is a unique identifier used by a device or CPU for data tracking. This binary address is defined by an ordered and finite sequence allowing the CPU to track the location of each memory byte.
2.Address Pointer in C
A pointer is a variable whose value is the address of another variable, i.e., direct address of the memory location. Like any variable or constant, you must declare a pointer before using it to store any variable address. The general form of a pointer variable declaration is −
3.Memory Mapping
Memory-mapping is a mechanism that maps a portion of a file, or an entire file, on disk to a range of addresses within an application’s address space. The application can then access files on disk in the same way it accesses dynamic memory.
Advantage of Memory mapping such as: Faster file access, sharing data between application, and efficient in a sense that it can access data without reading the whole file. 4.Memory Parity
Memory that uses a ninth bit for parity checking. The checking operation is performed by circuits on the motherboard, not on the memory chips themselves. When a parity error occurs, most computers simply display a “parity error” message, hang up and then must be rebooted.
5.Memory Allocation
Memory allocation is the process of setting aside sections of memory in a program to be used to store variables, and instances of structures and classes.
6.Static Memory Allocation
In simple terms, when declaring a variable, you can use that variable to access that specific block of memory
7.Dynamic Memory Allocation
In simple terms, this is when the OS designate/allocate a memory block and return the pointer referring to it. This is done when “new” or “malloc” is in invoked.
8.Heap
The Heap is that portion of computer memory, allocated to a running application, where memory can be allocated for variables, class instances, etc. From a program’s heap the OS allocates memory for dynamic use. Given a pointer to any one of the allocated blocks the OS can search in either direction to locate a block big enough to fill a dynamic memory allocation request.
9.malloc Function
“malloc” or “memory allocation” method in C is used to dynamically allocate a single large block of memory with the specified size. It returns a pointer of type void which can be cast into a pointer of any form. It initializes each block with default garbage value.
Syntax: (data type) malloc(byte-size)
10.Paging
As mentioned above, the memory management function called paging specifies storage locations to the CPU as additional memory, called virtual memory. The CPU cannot directly access storage disk, so the MMU emulates memory by mapping pages to frames that are in RAM.