Explain Belady's Anomaly. Why does it occur in FIFO page replacement but not in LRU?

Last updated 5 July 2026

  • Belady's Anomaly: for some reference strings, adding page frames increases page faults under FIFO (e.g. 1,2,3,4,1,2,5,1,2,3,4,5 faults more with 4 frames than 3).

  • FIFO evicts by arrival order, so the pages held with N+1 frames are not guaranteed to include those held with N frames.

  • LRU (and OPT) are stack algorithms: the resident set with N frames is always a subset of that with N+1, so more frames never hurts.

  • https://growthequityinterviewguide.com/firms/b-capital
  • https://www.interviewbit.com/sre-interview-questions/
  • https://medium.com/@avinashkumar808482/operating-system-interview-questions-2026-0db6b4674980
  • https://lmskkhsou.in/eservices/e-Resources/Resources/NEP%20Syllabus%202024/core/BCA_Syllabus.pdf
All Operating Systems interview questions