Summary


CPU scheduling is the task of selecting a waiting process from the ready queue and assigns it to CPU. FCFS scheduling is the simplest scheduling algorithm, but it can cause long waiting time. SJF scheduling gives the shortest average waiting time. The SJF algorithm can be considered as a priority-scheduling algorithm where the highest priority is given to the shortest job. Both priority and SJF scheduling may suffer from starvation. Aging is a technique to prevent starvation. RR scheduling allocates the CPU to the first process in the ready queue for a given slice time. Multilevel queue algorithms use different algorithms for various classes of processes. The scheduling algorithms are evaluated to be used in multiple processors and real time systems.

There are different methods to evaluate the CPU scheduling algorithms. Deterministic modeling takes a particular predetermined workload and defines the performance of each algorithm for that workload. Queueing models use mathematical analysis to determine the performance of an algorithm. Simulations methods record real data in trace tapes to evaluate the scheduling algorithms. Finally, implementing the schedule algorithm and run it a real operating system can be considered as the most accurate evaluation methods.