CS Atlas GATE 2027
Operating Systems course
0 / 58 complete

Operating Systems/Phase 2 · CPU Scheduling

Chapter review LI-2.2 · Item 19 of 58

Chapter 2.2 Lock-in

Read at your own pace. Try the questions before opening the answers.

On this page

Phase 2Ch 2.2 Time sharing and beyond

ACompressed recap

RR: FIFO queue, run min(q, remaining), arrivals at the same instant before the pre-empted process; large q → FCFS; useful fraction q/(q + s); count switches between different processes. Multilevel queues (fixed classes) vs MLFQ (demote on full quantum, aging promotes). CPU/I/O mixes: only CPU bursts compete, I/O overlaps; idle at the start and end; utilisation 1 − pⁿ.

BMerged rule card

2.2.1 Round robin and the time quantum

  • RR: FIFO ready queue; run min(q, remaining); unfinished → back; arrivals at the same instant queue before the pre-empted process.
  • Large q → FCFS; small q → overhead; useful fraction q/(q + s); max wait between turns (n − 1)q.
  • RR: worse average WT than SJF, better response time.
  • Context switches: count changes between different processes.

2.2.2 Multilevel queues, CPU and I/O bursts, CPU utilisation

  • Multilevel queue: fixed classes, fixed priority or time-sliced between queues; no movement.
  • MLFQ: start at the top; full quantum used → demote; aging → promote; defined by queues, algorithms, move rules.
  • CPU/I/O bursts: only CPU bursts compete; I/O overlaps; count idle at the start and end.
  • Utilisation ≈ 1 − pⁿ.

CInterleaved GATE-style questions

Q1 · NAT · 2 mark(s) — RR

All at 0 with bursts 24, 3, 3; RR with q = 4. Average waiting time (2 decimals)?

Numerical answer: ________

Q2 · NAT · 2 mark(s) — RR

RR with q = 3: P1 (AT 0, BT 5), P2 (AT 1, BT 3), P3 (AT 2, BT 1). Completion time of P1?

Numerical answer: ________

Q3 · NAT · 1 mark(s) — Overhead

q = 20 ms, context switch 5 ms. Fraction of CPU time spent on useful work?

Numerical answer: ________

Q4 · MCQ · 1 mark(s) — Response

Compared with SJF, round robin generally gives:

  1. (A) better average waiting time
  2. (B) fewer context switches
  3. (C) better response time
  4. (D) starvation of short jobs

Q5 · NAT · 1 mark(s) — Bound

RR with q = 10 ms and 6 processes always in the queue. Longest wait between two consecutive turns of one process?

Numerical answer: ________

Q6 · NAT · 2 mark(s) — Utilisation

3 processes each wait for I/O 50% of the time. CPU utilisation?

Numerical answer: ________

Q7 · MCQ · 1 mark(s) — Starvation

In a multilevel queue with fixed priority between queues, starvation can affect:

  1. (A) the highest-priority queue
  2. (B) no queue
  3. (C) only I/O-bound processes
  4. (D) the lowest-priority queue

Q8 · NAT · 2 mark(s) — MLFQ

MLFQ with quanta 4 and 8 in the top two queues, then FCFS. A process needs 25 ms of CPU. How many ms does it run in the FCFS queue?

Numerical answer: ________

DAnswer Vault

Try the questions first. Open when you are ready to check.

🔐 Open the Answer Vault

Q1 Answer: 5.66 to 5.67 · 2 mark(s)

(6 + 4 + 7)/3.

Re-read: Lesson 2.2.1 — Round robin and the time quantum

Q2 Answer: 9 · 2 mark(s)

P1 0–3, P2 3–6, P3 6–7, P1 7–9.

Re-read: Lesson 2.2.1 — Round robin and the time quantum

Q3 Answer: 0.8 · 1 mark(s)

20/25.

Re-read: Lesson 2.2.1 — Round robin and the time quantum

Q4 Answer: (C) · 1 mark(s)

Everyone gets a turn soon.

  • (A) is wrong: Usually worse.
  • (B) is wrong: More switches.
  • (D) is wrong: No starvation in RR.

Re-read: Lesson 2.2.1 — Round robin and the time quantum

Q5 Answer: 50 · 1 mark(s)

(n − 1)q.

Re-read: Lesson 2.2.1 — Round robin and the time quantum

Q6 Answer: 0.875 · 2 mark(s)

1 − 0.5³.

Re-read: Lesson 2.2.2 — Multilevel queues, CPU and I/O bursts, CPU utilisation

Q7 Answer: (D) · 1 mark(s)

Lower queues run only when higher ones are empty.

  • (A) is wrong: Always served first.
  • (B) is wrong: It can happen.
  • (C) is wrong: Not specific to I/O-bound.

Re-read: Lesson 2.2.2 — Multilevel queues, CPU and I/O bursts, CPU utilisation

Q8 Answer: 13 · 2 mark(s)

25 − 4 − 8.

Re-read: Lesson 2.2.2 — Multilevel queues, CPU and I/O bursts, CPU utilisation

Ready for the next idea?

Mark this item complete when you’ve finished reading and working through it.