CPU Scheduling Criteria
CPU Scheduling Criteria
GeeksforGeeks
CPU scheduling is essential for the system’s performance and ensures that processes are executed
correctly and on time. Different CPU scheduling algorithms have other properties and the choice of a
particular algorithm depends on various factors. Many criteria have been suggested for comparing CPU
scheduling algorithms.
Now let’s discuss CPU Scheduling has several criteria. Some of them are mentioned below.
1. CPU utilization
The main objective of any CPU scheduling algorithm is to keep the CPU as busy as possible.
Theoretically, CPU utilization can range from 0 to 100 but in a real-time system, it varies from 40 to 90
percent depending on the load upon the system.
2. Throughput
A measure of the work done by the CPU is the number of processes being executed and completed per
unit of time. This is called throughput. The throughput may vary depending on the length or duration of
the processes.
CPU Scheduling Criteria
3. Turnaround Time
For a particular process, an important criterion is how long it takes to execute that process. The time
elapsed from the time of submission of a process to the time of completion is known as the turnaround
time. Turn-around time is the sum of times spent waiting to get into memory, waiting in the ready queue,
executing in CPU, and waiting for I/O.
4. Waiting Time
A scheduling algorithm does not affect the time required to complete the process once it starts execution.
It only affects the waiting time of a process i.e. time spent by a process waiting in the ready queue.
5. Response Time
In an interactive system, turn-around time is not the best criterion. A process may produce some output
fairly early and continue computing new results while previous results are being output to the user. Thus
another criterion is the time taken from submission of the process of the request until the first response is
produced. This measure is called response time.
Response Time = CPU Allocation Time(when the CPU was allocated for the first) – Arrival
Time
6. Completion Time
The completion time is the time when the process stops executing, which means that the process has
completed its burst time and is completely executed.
7. Priority
If the operating system assigns priorities to processes, the scheduling mechanism should favor the higher-
priority processes.
8. Predictability
A given process always should run in about the same amount of time under a similar system load.
Example: Here are some examples of CPU scheduling algorithms that work well in different situations.
Round Robin scheduling algorithm works well in a time-sharing system where tasks have to be completed
in a short period of time. SJF scheduling algorithm works best in a batch processing system where shorter
jobs have to be completed first in order to increase throughput.Priority scheduling algorithm works better
in a real-time system where certain tasks have to be prioritized so that they can be completed in a timely
manner.
Selecting the correct algorithm will ensure that the system will use system resources efficiently, increase
productivity, and improve user satisfaction.
Conclusion
In Conclusion, CPU scheduling criteria play an important role in improving system performance. CPU
scheduling techniques encourage efficient use of system resource and effective task processing by
analysing and prioritising criteria such as CPU Utilization, Throughput, Turnaround Time, Waiting Time,
and Response Time. Selecting the appropriate algorithm for a given situation is crucial for increasing
system efficiency and production.
(A) FIFO
CPU utilization indicates the efficiency of utilizing the CPU’s processing power. Scheduling
algorithms aim to keep the CPU as busy as possible to achieve high utilization. However,
excessively high CPU utilization can lead to poor system responsiveness and potential
resource contention.
Throughput refers to the number of processes that are completed and leave the system within
a given time frame. Scheduling algorithms that maximize throughput often prioritize short
processes or those that require minimal CPU time, allowing more processes to be completed
in a given period.
Turnaround time measures the overall time a process takes to complete, from submission to
termination. Lower turnaround time indicates efficient process execution. Scheduling
algorithms that minimize turnaround time generally prioritize processes with shorter burst
times or high priority.
Some trade-off may include that the improving in throughput may lead to increment in
waiting time.
Improve