P4-L8: preemptive scheduling algorithms

0.0(0)
studied byStudied by 0 people
learnLearn
examPractice Test
spaced repetitionSpaced Repetition
heart puzzleMatch
flashcardsFlashcards
Card Sorting

1/11

encourage image

There's no tags or description

Looks like no tags are added yet.

Study Analytics
Name
Mastery
Learn
Test
Matching
Spaced

No study sessions yet.

12 Terms

1
New cards

preemptive scheduling

Allows the OS to interrupt a running process and switch to another, usually based on priority or time slice (quantum)

2
New cards

round robin

Each process gets a fixed time quantum to run. After that, it’s put at the back of the queue.
Fair
High context switching if quantum is too short

3
New cards

time quantum

The maximum slice of CPU time a process gets in Round Robin before being preempted.

4
New cards

quantum based priority scheduling (QBPS - windows)

A hybrid system used in Windows:

  • Each process has a priority level

  • Higher-priority gets longer quantum and earlier access

  • May preempt mid-quantum if a higher-priority process arrives

5
New cards

aging (in QBPS)

Processes gain priority over time to prevent starvation. Can be:

  • Linear

  • Step-based

  • Exponential

6
New cards

completely fair scheduler (CFS - linux)

Each process gets a fair share of CPU time, tracked by vruntime (virtual runtime).
Lower vruntime = more CPU time

7
New cards

runtime

CFS metric that tracks how much CPU time a process has used relative to others.
Less vruntime = process has gotten less CPU = higher priority

8
New cards

red black tree (CFS)

Balanced binary tree used in CFS to organize processes by vruntime for efficient scheduling.

9
New cards

fairness

CFS and RR prioritize fairness — ensuring all processes eventually get CPU time.

10
New cards

starvation prevention

  • RR: every process gets a turn

  • CFS: dynamically prioritizes under-served processes

  • QBPS: aging boosts priority over time

11
New cards

context switching

Can increase with short time slices. Tradeoff between responsiveness and CPU overhead.

12
New cards

preemptive priority scheduling

Higher-priority process can interrupt a lower-priority one — can lead to starvation without aging.