Virtual Memory Flashcards
What does virtual memory mean?
It means that there is no chance of programs overwriting each other
What does segmentation allow?
It allows us to divide the memory space into purposeful segments and assign virtual addresses to them
What are the problems with segmentation?
- Still have to load libraries multiple times
- Still can’t use more memory than actually exists
- Programs will never have access to a full segment: some of it is used for addressing
- Problems with memory holes not fixed
What does paging do?
Paging splits available RAM into pages which give programs virtual space.
What are pages useful for?
They can be re used to save memory
How does the OS load data from secondary storage to RAM?
- It determines the location of data on disk
- Obtains an empty page from RAM to use as a container for the data
- Load the requested data into an available page
- Update the page table to refer to the new page
- Return control to program
What is swapping?
A way of moving a whole process from the RAM onto the HDD
What does swapping do?
Saves the status of the currently running program
Is swapping or paging slower?
Swapping is very slow, while paging is slow.