Home › GATE CSE › computerscience › Operating Systems › For workloads consisting MOSTLY of I/O-bound job…
For workloads consisting MOSTLY of I/O-bound jobs (jobs that do short CPU bursts then wait for I/O), the IDEAL CPU scheduler should
Agive long uninterrupted CPU time to each job
Buse a long time-slice quantum (~1 second)
Cschedule I/O-bound jobs quickly so they can issue I/O
Dignore I/O-bound jobs and only schedule CPU-bound jobs
Answer & Solution
Correct answer: C. schedule I/O-bound jobs quickly so they can issue I/O
1. OSTEP §7.7 (Incorporating I/O) discusses the interaction between I/O and CPU scheduling.
2. I/O-bound job pattern: a brief CPU burst → issue I/O → wait blocked for I/O → repeat. While waiting, the CPU is free for OTHER jobs.
3. To MAXIMISE OVERLAP and CPU utilisation, the scheduler should:
a) Run an I/O-bound job briefly so it can dispatch its I/O.
b) While that job is blocked on I/O, run a CPU-bound job in the foreground.
c) When the I/O completes, briefly preempt to handle the now-runnable I/O-bound job again.
4. This is exactly what MLFQ does, by inferring I/O-bound character (jobs that yield before exhausting their time slice get a priority boost).
5. Option A would starve interactive responsiveness. Option B has the same problem at a longer time scale. Option D ignores half the workload.
_Source: OSTEP Ch 7, §7.7 (Incorporating I/O), p. 11-12._
Related questions
On a MULTI-CORE system, a SPIN LOCK is generallyDisabling INTERRUPTS as a way to implement mutual exclusion on a single-CPU system isA LIVELOCK differs from a DEADLOCK in thatSuppose thread A acquires lock L1, then thread B acquires lock L2. Now A tries to acquire Without atomic hardware support, building a correct mutual-exclusion lock for $N \geq 2$ tA CRITICAL SECTION isLinux's `pthread_mutex_lock()` is typically implemented as a HYBRID:What is the PRIMARY problem with using a SPIN LOCK on a SINGLE-CPU uniprocessor system (wi