CS FundamentalsHardDeloitte · IBM campus pattern
Reference string: 1, 4, 1, 6, 2, 3, 6, 1, 2, 4, 3, 6, 4. With 4 frames, initially empty, how many page faults do FIFO, LRU and Optimal (Belady's MIN) replacement cause, respectively?
- A. FIFO 8, LRU 8, Optimal 7
- B. FIFO 8, LRU 8, Optimal 6
- C. FIFO 9, LRU 8, Optimal 6
- D. FIFO 8, LRU 9, Optimal 6
Correct answer: B. FIFO 8, LRU 8, Optimal 6
Simulating each policy frame-by-frame on this string with 4 frames gives FIFO 8 faults, LRU 8 faults and Optimal 6 faults; Optimal is always the lower bound since it evicts the page used farthest in the future.
More Operating Systems questions
- Reference string: 1, 4, 1, 6, 2, 3, 6, 1, 2, 4, 3, 6, 4. With 3 frames, initially empty, how many page faults does FIFO replacement cause?
- Reference string: 8, 2, 9, 2, 4, 8, 9, 4, 2, 8, 4, 9, 2. With 3 frames, initially empty, how many page faults do FIFO, LRU and Optimal…
- Reference string: 8, 2, 9, 2, 4, 8, 9, 4, 2, 8, 4, 9, 2. With 4 frames, initially empty, how many page faults does LRU replacement cause?
- Reference string: 3, 8, 2, 8, 9, 3, 2, 9, 3, 8, 2, 9, 8. With 4 frames, initially empty, how many page faults do FIFO, LRU and Optimal…
- Reference string: 3, 8, 2, 8, 9, 3, 2, 9, 3, 8, 2, 9, 8. With 3 frames, initially empty, how many page faults does FIFO replacement cause?
- Reference string: 6, 3, 1, 0, 3, 6, 1, 0, 6, 3, 1, 6. With 3 frames, initially empty, how many page faults do FIFO, LRU and Optimal…