CS FundamentalsHardProduct-company MCQ pattern
In preemptive SRTF, a running process can be interrupted the instant a newly arrived process has a strictly smaller remaining burst. Why is this preemption check unnecessary at every single tick for non-preemptive SJF?
- A. Because non-preemptive SJF only re-selects the next process when the CPU becomes free (the running process is never interrupted), so comparisons against the running process's remaining time are irrelevant until it finishes
- B. Because non-preemptive SJF has no concept of burst time
- C. Because ties cannot occur under non-preemptive SJF
- D. Because non-preemptive SJF never looks at remaining burst at all
Correct answer: A. Because non-preemptive SJF only re-selects the next process when the CPU becomes free (the running process is never interrupted), so comparisons against the running process's remaining time are irrelevant until it finishes
Non-preemptive SJF commits to a process once started: it only compares candidates in the ready queue at the moment the CPU is free (idle or a process just completed), never mid-burst. SRTF, being preemptive, must re-evaluate on every new arrival in case a shorter job has just shown up.
More Operating Systems questions
- Which statement about multilevel feedback queue (MLFQ) scheduling is correct?
- A disk has an average seek time of 4 ms, rotational latency (average) of 3 ms, and a transfer rate that takes 1 ms per 4 KB block. What is…
- A disk rotates at 6000 RPM. What is the average rotational latency (time for half a rotation)?
- C-SCAN (Circular SCAN) differs from plain SCAN in which way?
- A disk has cylinders 0 to 199. Head is at cylinder 50, moving towards cylinder 199. Pending requests: 182, 20, 97, 64, 160. Using C-SCAN…
- A disk has cylinders 0 to 199. The head is at cylinder 50 and moving towards cylinder 0. Pending requests: 182, 20, 97, 64, 160. Using…