An active process in this system accesses unique pages during its execution, and none of the pages are swapped out to disk. After it completes the page accesses, let denote the minimum and denote the maximum number of pages across the two levels of the page table of the process.
The value of is ___________.
View worked solution
Answer: 1028
To solve this problem, we first analyze the structure of the 2-level page table:
- Page Size: (Offset = bits).
- Page Table Entry (PTE) size: .
- Entries per page: entries.
Since the system uses a 2-level page table for a 32-bit address space, the virtual address is split as follows:
Thus, the outer page directory contains entries, pointing to a maximum of inner page tables. Each inner page table covers pages of virtual memory.
The process accesses unique pages. The outer page directory is always allocated ( page).
1. Minimum Pages ():
To minimize the number of inner page tables, the pages should be clustered as contiguously as possible. Since each inner page table covers pages, the minimum number of inner page tables required is:
2. Maximum Pages ():
To maximize the number of inner page tables, the pages should be distributed across as many different inner page tables as possible. Since there are at most inner page tables and , we can distribute the pages such that every one of the inner page tables contains at least one active page.
Calculating :
Free practice · Your answers on this page are not saved.
