Main memory (RAM) is the primary memory, which a CPU can access directly. Therefore, any instruction in execution and data that is used by instruction must be in one of the direct storage access devices (RAM).
The run-time mapping to physical address from virtual address is done by a hardware device called the memory management unit (MMU).
Memory management can be broadly classified into two types:
- Internal fragmentation can be described as when there is a left-over space that cannot be utilized further.
- External fragmentation takes place when there is enough space to satisfy the request of a process but it is not contiguous, so it cannot be utilized further.
The word contiguous
here refers to the shared allocation of a memory resource.
The two important types of contiguous memory management are: