Exercise 5
Group 1: November 12, at 16-18 pm (T/B181)
Group 2: November 12, at 10-12 am (T/B180)
CPU scheduling
Process Arrival time Burst time Priority
------- ------------ ---------- --------
P1 0 10 3
P2 2 1 1
P3 3 2 3
P4 4 1 4
P5 6 5 2
Draw a Gantt chart illustrating the execution of these processes using a preemptive priority scheduling. (Use FCFS for equal priority processes)
Calculate a waiting time and a turnaround time for each process, and an average waiting time and an average turnaround time for the scheduling.
Process Burst time
------- ----------
P1 10
P2 1
P3 2
P4 1
P5 5
The processes are assumed to have arrived in the order
P1,P2,P3,P4,P5, all at time 0.
Draw a Gantt chart illustrating the execution of these processes using RR (time quantum = 1 ms) scheduling.
Calculate a waiting time and a turnaround time for each process, and an average waiting time and an average turnaround time for the scheduling.
Process Arrival time Burst time
------- ------------ ----------
P1 0 10
P2 2 1
P3 3 2
P4 4 1
P5 6 5
Draw a Gantt chart illustrating the execution of these processes
using RR (time quantum = 3 ms) scheduling.
Calculate a waiting time and a turnaround time for each process, and an average waiting time and an average turnaround time for a scheduling.
Process Arrival time Burst time
------- ------------ ----------
P1 0 17
P2 12 25
P3 28 8
P4 36 32
P5 46 18
Draw a Gantt chart illustrating the execution of these processes using a Multilevel Feedback Queue Scheduling. Use the same structure of the model as in the lectures: (queue 0: time quantum 8), (queue 1: time quantum 16), (queue 2: FCFS). Queues 0 and 1 are served as FCFS with time quantums 8 and 16, respectively.