Scheduler Notes
Time slices, priorities, and virtual runtime in the classic CFS design.
Round-robin scheduling gives runnable tasks a turn in a fixed rotation. Priority scheduling chooses according to priority, which can leave lower-priority tasks waiting unless the policy addresses starvation.
The classic Completely Fair Scheduler tracks virtual runtime: CPU time adjusted for a task’s weight. Runnable tasks are ordered in a red-black tree, and the scheduler favors the task with the smallest virtual runtime.
Nice values affect a task’s weight and therefore its share of CPU time. They do not assign a fixed number of milliseconds. Compare two CPU-bound tasks with different weights to see how their virtual runtimes advance.








