Virtual Memory Flashcards
what is virtual memory
provides a virtualisation of the address space
each process has a private map to translate virtual addresses into non conflicting physical addresses
what are the benefits of virtual memory
we can fill physical memory with addresses appearing where we want them.
can use physical memory sensibly without having to swap
what is paging or swapping
pages are copied onto disk to free up space.
we perform paging or swapping to bring them into main memory
this is controlled by the scheduler
what is the memory management unit
the hardware that implements memory mapping
a 64 bit machine can address
2^64 locations
what is a page
a division of a virtual memory system. the address space is divided into pages of a fixed size.
indivisible blocks assigned to processes
when in a page fault generated
when the virtual page is not resident in the MMU
what is the number of pages in a virtual memory system
address space / page size
what is a memory fault
an exception caused by: privilege violation page fault time out corrupt memory
what is a page state
each page in virtual memory will have its own state: unallocated allocated clean dirty swapped out
what happens after a page fault
allocate a page and fetch from disk
what does the MMU do
perform memory mapping and check privilege
what are the inputs to the MMU
virtual memory address
operation
processor privilege info
what are the outputs of the MMU
success:
physical memory address
cacheability info
not success:
no physical memory
illegal operation
privilege violation
what is a page table
specifies the translation from virtual to physical page address