0% found this document useful (0 votes)
8 views

Process Scheduling

Process Scheduling

Uploaded by

Will Aldea
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
8 views

Process Scheduling

Process Scheduling

Uploaded by

Will Aldea
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 6

Process Scheduling

2 Types of Algorithm used


I. Non-preemptive scheduling is employed when a process terminates or
transitions from running to waiting state

*Non Preemptive Algorithms


First come first Serve - FCFS
Shortest Job First - SJF

II. Preemptive scheduling is when a process transitions from a running state to a ready
state or from a waiting state to a ready state

*Preemptive Algorithms
Round Robin - RR
Shortest Remaining Time First - SRTF
Criteria in Choosing Algorithms
1. Increases CPU Utilization
2. Increases Throughput- Number of Outputs
3. Lower Turn Around Time
4. Lower waiting Time
5. Fairness and Quick Response Time
Sample Problem

Job At Bt Priority
A 0 13 4
B 3 5 3
C 8 4 5
D 15 6 1
E 17 9 2
Output Results Inputs Needed

1. Gantt Chart 1. No of Jobs


2. Turn Around Time 2. At = Arrival Time
3. Waiting Time 3. Bt = Burst Time
4. % CPU Utilization
FCFS
A B C D E

0 3 8 15 17

Gannt Chart
A B C D E
0 13 18 22 28 37
A B C D E
% CPU Utilization = burst time x 100
end time
37 x 100 = 100%
37
tt = end time – at wt = tt – bt
ttA = 13 - 0 = 13 wtA = 13 – 13 = 0
ttB = 18 - 3 = 15 wtB = 15 – 5 = 10
ttC = 22 - 8 = 14 wtC = 14 – 4 = 10
ttD = 28 - 15 = 13 wtD = 13 – 6 = 7
ttE = 37 - 17 = 20 wtE = 20 – 9 = 11
ttAVE = 75 = 15 wtAVE = 38 = 7.6
5 5

You might also like