CPU scheduling algorithms require CPU time and IO time required for its execution. CPU time is time taken by CPU to carry out the process while I/O time illustrates the time required for I/O operation by the process.
The execution of multiple processes in an optimised way is based on different kinds of algorithms, like FCFS, Shortest Job First etc., which depend on the time frame values, like the Arrival Time, Burst Time, Waiting Time etc.
1. Arrival Time (AT) :
Arrival time is the point of time in milli seconds at which a process arrives at the ready queue to begin the execution. It is merely independent of the CPU or I/O time and just depicts the time frame at which the process becomes available to complete its specified job.The process is independent of which process is there in the Running state. Arrival Time can be calculated as the difference of the Completion Time and the Turn Around Time of the process.
Arrival Time (A.T.) = Completion Time (C.T.) - Turn Around Time (T.A.T)
2. Burst Time (BT) :
Burst Time refers to the time required in milli seconds by a process for its execution. The Burst Time takes into consideration the CPU time of a process. The I/O time is not taken into consideration. It is called as the execution time or running time of the process. The process makes a transition from the Running state to the Completion State during this time frame. Burst time can be calculated as the difference of the Completion Time of the process and the Waiting Time, that is,
Burst Time (B.T.) = Completion Time (C.T.) - Waiting Time (W.T.)
The following table illustrates the Arrival and Burst time of three processes P1, P2 and P3. A single CPU is allocated for the execution of these processes.
|Processes||Arrival Time (in ms)||Burst Time (in ms)|
If we compute the Gantt chart, based on FCFS scheduling where the process that comes first in the ready queue is executed first. The processes arrival decides the order of execution of the process for time equal to its Burst time.
Since, the process P2 arrives at 4ms, and process P1 requires 3ms for its execution (=Burst Time), CPU waits for 1ms, that is the idle time for the CPU, where it doesn’t perform any process execution. The last process to get executed is P3.
The following table illustrates the key differences in the Arrival and Burst Time respectively :
|Arrival Time||Burst Time|
|Marks the entry point of the process in the queue.||Marks the exit point of the process in the queue.|
|Computed before the execution of process.||Computed after the execution of process.|
|Related to the Ready State of the CPU.||Related to the Running State of the CPU.|
Attention reader! Don’t stop learning now. Get hold of all the important DSA concepts with the DSA Self Paced Course at a student-friendly price and become industry ready.
- Shortest Job First CPU Scheduling with predicted burst time
- Priority CPU Scheduling with different arrival time - Set 2
- Difference between Seek Time and Transfer Time in Disk Scheduling
- Difference between Turn Around Time (TAT) and Waiting Time (WT) in CPU Scheduling
- Difference between Transfer Time and Disk Access Time in Disk Scheduling
- Difference between Seek Time and Disk Access Time in Disk Scheduling
- Least Slack Time (LST) scheduling Algorithm in real-time systems
- Difference between Rotational Latency and Transfer Time in Disk Scheduling
- Difference between Seek Time and Rotational Latency in Disk Scheduling
- Difference between Compile Time and Execution Time address binding
- Difference between Compile Time and Load Time address Binding
- Difference between Load Time and Execution Time address binding
- Difference between Compile-time and Run-time Polymorphism in Java
- Difference between Rotational Latency and Disk Access Time in Disk Scheduling
- Difference between Time Sharing OS and Real-Time OS
- Scheduling in Real Time Systems
- Difference between Hard real time and Soft real time system
- Longest Remaining Time First (LRTF) CPU Scheduling Program
- Longest Remaining Time First (LRTF) CPU Scheduling Algorithm
- Round Robin Scheduling with different arrival times
If you like GeeksforGeeks and would like to contribute, you can also write an article using contribute.geeksforgeeks.org or mail your article to email@example.com. See your article appearing on the GeeksforGeeks main page and help other Geeks.
Please Improve this article if you find anything incorrect by clicking on the "Improve Article" button below.