CS FundamentalsModerateGATE CS (PYQ pattern)
A machine has 48-bit virtual addresses, 16 KB pages and 8-byte page-table entries. Every page-table node must fit in one page, lower levels are full, and the fewest levels are used (the top level takes the leftover bits). How many levels are there, and how many entries does the top-level table have?
- A. 4 levels, 2 entries
- B. 3 levels, 2048 entries
- C. 4 levels, 2048 entries
- D. 3 levels, 4096 entries
Correct answer: A. 4 levels, 2 entries
Offset = 14 bits; a page holds 16384 / 8 = 2048 entries = 11 index bits. 48 - 14 = 34 index bits = 11 + 11 + 11 + 1, so 4 levels with a 2-entry top table. Three full levels cover only 33 bits; 4096 entries assumes 4-byte entries.
More Operating Systems questions
- Two processes bounce a 1-byte message through a pair of pipes: 100,000 round trips take 1.2 s, and each round trip contains two context…
- MFU replacement with 3 frames (initially empty): the victim is the resident page with the LARGEST reference count since it was loaded…
- FIFO page replacement is run on the string 6, 1, 7, 2, 7, 2, 1, 5, 1, 1, 7, 5, 3, 1, 1, 7, 4, 5, 3, 4 (memory initially empty) with each…
- The clock algorithm uses 3 frames (initially empty); the reference bit is set when a page is loaded and on every hit. On a fault the hand…
- A counting semaphore S starts at 3 and is implemented so that wait() decrements S and blocks the caller if S becomes negative, while…
- A 16-core machine must unmap a page that all cores have in their TLBs. The initiating core sends an inter-processor interrupt to each of…