CS FundamentalsVery hardGATE CS
Reference string: 7, 2, 3, 1, 2, 5, 3, 4, 6, 7, 7, 1, 0, 5, 4, 6, 2, 3, 0, 1. With 3 frames (initially empty), what are the page-fault counts for FIFO, LRU and OPT respectively?
- A. 17, 18, 13
- B. 17, 19, 13
- C. 18, 17, 13
- D. 17, 18, 14
Correct answer: A. 17, 18, 13
Simulating each policy carefully gives FIFO 17, LRU 18, OPT 13. OPT is a lower bound for any algorithm on the same string and frame count.
More Operating Systems questions
- Reference string: 1, 2, 1, 3, 1, 2, 4, 5, 4, 2, 5, 3, 4, 2, 3 frames, initially empty. LFU replacement is used: the victim is the resident…
- Reference string: 0, 4, 1, 4, 2, 4, 3, 4, 2, 4, 0, 4, 1, 4, 2, 4, 3, 4. How many page faults does LRU give with 2, 3, 4 and 5 frames…
- TLB access 2 ns (looked up first), memory access 50 ns, two-level page table, TLB hit ratio 98%. A fraction 10⁻⁵ of ALL accesses…
- A machine has 57-bit virtual addresses (5-level paging style), 4 KB pages and 8-byte page-table entries, with every page table fitting in…
- A system has 46-bit virtual addresses, 16 KB pages and 4-byte PTEs; each page table must fit in one page. How many levels of page tables…
- Segment table (base, length): S0 (219, 600), S1 (2300, 14), S2 (90, 100), S3 (1327, 580), S4 (1952, 96). What are the physical addresses…