CS FundamentalsHardGATE CS (PYQ pattern)
FIFO page replacement is run on the string 6, 1, 7, 2, 7, 2, 1, 5, 1, 1, 7, 5, 3, 1, 1, 7, 4, 5, 3, 4 (memory initially empty) with each frame count from 1 to 7. For how many of the six increases f to f + 1 (f = 1..6) does the number of faults go UP?
- A. 1
- B. 2
- C. 0
- D. 3
Correct answer: A. 1
Fault counts for 1..7 frames are [18, 14, 10, 11, 7, 7, 7]; the counts rise at 1 of the six steps (frames 3→4).
More Operating Systems questions
- The clock algorithm uses 3 frames (initially empty); the reference bit is set when a page is loaded and on every hit. On a fault the hand…
- A counting semaphore S starts at 3 and is implemented so that wait() decrements S and blocks the caller if S becomes negative, while…
- A 16-core machine must unmap a page that all cores have in their TLBs. The initiating core sends an inter-processor interrupt to each of…
- Two periodic tasks with deadline = period and zero release offset: T1 (C=2, P=5) and T2 (C=4, P=7). Total utilisation is 2/5 + 4/7 ≈…
- Three periodic tasks (deadline = period, all released at t=0) are scheduled by preemptive rate-monotonic scheduling: T1 (C=2, P=5), T2…
- Two processes use shared variables flag[2] (initially 0) and turn. Process i (j = 1−i) runs: V1: flag[i]=1; turn=j; while(flag[j] &&…