CS FundamentalsVery hardGATE CS
32-bit addresses, 4 KB pages, 4-byte PTEs, two-level paging (10/10/12). A process uses only 8 MB of code at virtual address 0 and 4 MB of stack at the very top of the address space. How much memory do its page tables occupy?
- A. 4 MB
- B. 12 KB
- C. 16 KB
- D. 4 KB
Correct answer: C. 16 KB
Each inner table maps 4 MB. Code needs 2 inner tables, stack needs 1; plus the outer table: 4 pages × 4 KB = 16 KB. A flat table would need 4 MB.
More Operating Systems questions
- A system has resource types A, B, C. Available = (2,1,0). Allocation: P0 (1,1,0), P1 (0,1,2), P2 (2,0,1), P3 (1,0,0). Max: P0 (3,2,2), P1…
- Banker's algorithm state: Available = (3,3,2). Allocation: P0 (0,1,0), P1 (2,0,0), P2 (3,0,2), P3 (2,1,1), P4 (0,0,2). Max: P0 (7,5,3), P1…
- Two resource types X, Y. Available = (1,1). Allocation: P0 (1,0), P1 (0,1), P2 (1,1). Max: P0 (2,1), P1 (1,2), P2 (2,2). How many of the…
- A system has R identical instances of a resource shared by 4 processes needing at most 3, 4, 5 and 2 instances respectively. What is the…
- n processes share 12 identical units of a resource, and each process may need up to 4 units. What is the largest n for which deadlock is…
- k processes each need at most 3 instances of a resource that has 7 instances in total. Requests are made one instance at a time. What is…