Memory management intends to satisfy Flashcards
It is not possible for a programmer to know in advance which programs will reside int he main memory at the exact time of the program execution.
Hence, the possibility that the program may be moved within the main memory due to swapping should always be considered. In addition, swapping active processes in and out of the main memory to maximize process utilization is also highly observed.
Relocation
Each process should be protected against unwanted interference by other processes, whether accidental or intentional.
Thus, programs in other processes should not be able to reference memory locations in a process, for reading or writing purposes, without permission.
Protection
Any protection mechanism must have the flexibility to allow several processes to access the same portion of the main memory.
If a number of processes are executing the same program, it is advantageous to allow each process to access the same copy of the program rather than have its own separate copy.
Sharing
Most programs are organized into modules, some of which are unmodified, read-only or execute-only, and some of which contain data that are modifiable.
It would be great advantage if the operating system and computer hardware could effectively manage user programs and data in modules.
Logical organization
The task of moving and organizating information flow between the main and the secondary memory should be a system responsibility.
This task is the essence of memory management.
Computer memory is organized into at least two (2) levels, which are as follows:
- Main memory
- Secondary memory
Physical organization
This is a volatile memory that provides fast access at a relatively high cost. The main memory technically holds programs and data that are currently in use.
Main memory
This is usually a non-volatile memory at a cheaper cost with slower access. A secondary memory of large capacity is a good storage of programs and data for a longer term.
Secondary memory