Virtual Memory & Paging


Answer & solution
Official answer: C
Let each page contain 2p bytes. Under the standard fixed-width organization, a 32-bit PTE or physical-address entry occupies four bytes, so each page-sized table contains 2p−2 entries and each of the three levels uses p−2 index bits. The page offset uses p bits. Covering the 46-bit virtual address therefore gives 3(p−2)+p=46, hence 4p=52 and p=13. The page size is 213 bytes=8 KiB, labeled 8 KB in the options, so C. This uses 32-bit entries at the upper levels as well as the stated 32-bit leaf PTE, page-sized table blocks, full address-space coverage, and the usual binary KB convention.
A page of 2^pbytes contains 2p/4=2p−2table entries when each occupies 4 bytes. Hence each level contributes p−2 index bits and the final byte offset contributes pbits. With three levels, the address budget is(p−2)+(p−2)+(p−2)+p=46. Solving gives p=13and8192 bytes. The result is conditional on the usual fixed-width pointer entries at upper levels; the problem explicitly gives the leaf PTE size and implies that conventional organization.