Lecture 2 Flashcards
Paging
computer stores and retrieves pages from secondary
storage for use in main memory.
Describe the general correlation with page size and fragmentation.
Large page size = more fragmentation
Small page size = less fragmentation
Key data-structure used in any paging algorithm
Page table
Page Table
The page table is a data structure that (for each process) maps page numbers (references to memory chunks in virtual memory) to frame numbers (memory
slots in physical memory)
Where is the page table for each process located?
Main memory
What if a page cant fit into the page table.
MMU executes a page already in the page table.
Larger page is entered into page table.
Page table size
large enough to hold as many pages as we
would expect to have running (concurrently in physical memory).
Page Offset
Indicates how large the page is.
Page Table Entry (P T E)
ith entry (row) of a page table and is implemented as a pointer to an actual memory page
Permission bits of PTE
Tell the memory management unit something about the page, for example, whether the page is read-only, read-write, write-only, and valid.
Valid-bit = 1
Page is in main memory.
Valid-bit = 0
Page not in main memory and must be swapped in from virtual memory.
Dirty bit
Tells the memory management unit whether the page has been modified by the processor or not (since
being swapped in)
How is access to shared pages dealt with?
By changing permission bits in the page table.
Protection
effectively and efficiently allowing multiple processes to safely access a limited physical memory space