CS FundamentalsModerateGATE CS
Which page-replacement algorithms are stack algorithms (the set of pages in memory with n frames is always a subset of the set with n + 1 frames), and therefore can never show Belady's anomaly?
- A. FIFO and LRU
- B. FIFO and Second Chance
- C. Optimal and FIFO
- D. LRU and Optimal
Correct answer: D. LRU and Optimal
LRU and OPT satisfy the inclusion property, so adding frames never adds faults. FIFO and its variant second chance (clock) are not stack algorithms and can exhibit Belady's anomaly.
More Operating Systems questions
- A system has a 3-level page table and a TLB. TLB lookup = 20 ns, memory access = 100 ns, TLB hit ratio = 95%. The TLB is searched before…
- Memory access time is 100 ns, average page-fault service time is 8 ms, and the page-fault rate is 1 in 100,000 accesses. Ignoring TLB…
- Memory access takes 200 ns and a page fault takes 10 ms to service. To keep the effective access time within 10% of the memory access…
- A machine has 36-bit virtual addresses, 8 KB pages and 4-byte page-table entries. A two-level page table is used in which the inner page…
- A system has 32-bit virtual addresses, 1 GB of physical memory, 4 KB pages, and each page-table entry holds the frame number plus a valid…
- Page size is 2 KB. The page table maps page 0 → frame 6, page 1 → frame 2, page 2 → frame 9, page 3 → frame 4. What physical address does…