1/16
Looks like no tags are added yet.
Name | Mastery | Learn | Test | Matching | Spaced | Call with Kai | Chat |
|---|
No analytics yet
Send a link to your students to track their progress
principle of locality means
a process only accesses a small portion of its address space during any given period of time
virtual memory does not store the entire process image in main memory hence
signficantly increse the degree of multi-programming and even run a process with larger address space then the main memory
Principle of locality also referred to as
locality of reference
Principle of locality includes two types of locality
Spatial locality & Temporal locality
Spatial locality
Reference memory addressees near previously referenced addresse
Temporal locality
reference memory addresses that have been referenced in the past
Virtual Memory Challenge
Need to identify which portions of the address space of process should be stored in the main memory & The access pattern of a process may change over time
The rest of the process image is stored in a reserved section of the secondary storage known as
swap space
Portions of process image may need to move back and fourth between
main memory & swap space
Trade off between amount of information movement between main memory and swap space & amount of process image kept in memory are
lower degree of multi programming & too much information movement between main memory and swap space
What happens if too much of each process image is kept in main memory?
It lowers the degree of multiprogramming because fewer processes can fit in memory.
Why can a low degree of multiprogramming reduce CPU utilization?
If the few processes in memory are waiting for I/O, there may be no ready process for the CPU to execute.
Does low multiprogramming cause processes to perform more I/O?
No. It means fewer alternative processes are available while another process is waiting for I/O.
What is the trade-off in virtual memory management?
Keeping too much of each process in memory lowers multiprogramming, while keeping too little causes excessive paging between main memory and swap space.
What happens if too little of a process image is kept in main memory
It causes frequent page faults and excessive movement of pages between main memory and swap space. The process spends more time waiting for required parts of its address space to be loaded into memory.