GATE Computer ScienceHardGATE CS (PYQ pattern)

A 32-bit machine uses a 2-level page table with 4 KB pages and 4-byte entries (10 + 10 + 12 bit split). A process uses exactly 4 MB + 8 KB of contiguous virtual memory starting at virtual address 0, plus one separate 4 KB page at address 0xFFFFF000. How many bytes of page-table pages must be allocated (count the top-level table)?

  1. A. 8192
  2. B. 12288
  3. C. 16384
  4. D. 20480

Correct answer: C. 16384

4 MB + 8 KB = 1026 pages needing 2 second-level tables (1024 pages each = 4 MB, then 2 pages in a second table → 2 tables); the page at 0xFFFFF000 needs a third second-level table. Total = 1 top-level + 3 second-level = 4 pages of 4096 = 16384 bytes.

More Computer Organization and Architecture questions

Exams that ask this topic