The time slice
Three long jobs are running when you press a key. How long until the keypress gets the CPU, and what does a quicker answer cost?
One CPU, three long jobs already running, and a keypress that arrives 100 ms in and needs 5 ms. Pick the rule that decides who runs next and how long a turn lasts. The panels show how long the keypress waits, the average time to finish, and the CPU lost to swapping jobs.
On a narrow screen the three panels stack below the tabs and slider. The table scrolls sideways.
try this Click Take turns, drag How long one turn lasts from 100 ms down to 1 ms, and watch The keypress waits.
Included with a plan
This lab is included with a plan. The first three lessons of every track are free, with their boards and videos. A plan unlocks every lesson, board, video, lab and paper for one price.