CS FundamentalsVery hardGATE CS (PYQ pattern)

A process on a 4-level, 48-bit paging system (9 index bits per level, 4 KB pages, 4 KB page-table pages) maps three regions: 2 MB at 0x400000, 6 MB at 0x10000000 and a 1 MB stack ending at 0x800000000000. Page-table pages exist only where needed. How many page-table pages (all four levels, including the root) does the process use?

  1. A. 8
  2. B. 12
  3. C. 14
  4. D. 10

Correct answer: D. 10

Count distinct nodes per level: 1 root; level-3 nodes covering 512 GB slots; level-2 nodes covering 1 GB; level-1 (leaf) tables covering 2 MB. The regions need 10 pages in total.

More Operating Systems questions

Exams that ask this topic