Bird
Raised Fist0

Which trade-off is most significant when choosing non-preemptive SJF over preemptive SJF in a system with unpredictable process arrivals?

medium🪤 Complexity Trap Q6 of Q15
Operating Systems - Shortest Job First (SJF) - Preemptive vs Non-Preemptive
Which trade-off is most significant when choosing non-preemptive SJF over preemptive SJF in a system with unpredictable process arrivals?
ANon-preemptive SJF reduces starvation but increases average waiting time
BNon-preemptive SJF eliminates context switch overhead but risks longer waiting times for short jobs
CPreemptive SJF guarantees fairness but causes higher CPU idle time
DPreemptive SJF simplifies implementation but increases response time
Step-by-Step Solution
Solution:
  1. Step 1: Understand non-preemptive SJF effects on waiting time and overhead

    It avoids context switches by running processes to completion, but short jobs may wait longer.
  2. Step 2: Contrast with preemptive SJF

    Preemptive SJF can interrupt to serve short jobs quickly but incurs overhead.
  3. Final Answer:

    Option B -> Option B
  4. Quick Check:

    Non-preemptive reduces context switches but risks longer waits for short jobs [OK]
Quick Trick: Non-preemptive reduces switches but delays short jobs [OK]
Common Mistakes:
MISTAKES
  • Confusing starvation effects
  • Assuming preemptive causes CPU idle time
  • Believing preemptive simplifies implementation
Trap Explanation:
PITFALL
  • Candidates mix up starvation and waiting time trade-offs between preemptive and non-preemptive.
Interviewer Note:
CONTEXT
  • Evaluates nuanced understanding of scheduling trade-offs in dynamic environments.
Master "Shortest Job First (SJF) - Preemptive vs Non-Preemptive" in Operating Systems

2 interactive learning modes - each teaches the same concept differently

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More Operating Systems Quizzes