This course is run at the The University of Nottingham within the School of Computer Science & IT. The course is run by Graham Kendall (EMAIL : gxk@cs.nott.ac.uk)
For FCFS the process would be executed in the following order, with the following wait times
Process | Burst Time | Wait Time |
P1 | 9 | 0 |
P2 | 33 | 9 |
P3 | 2 | 42 |
P4 | 5 | 44 |
P5 | 14 | 49 |
Therefore, the average waiting time is ((0 + 9 + 42 + 44 + 49) / 5) = 28.80 milliseconds
For SJF (non preempted) the processes would run as follows
Process | Burst Time | Wait Time |
P3 | 2 | 0 |
P4 | 5 | 2 |
P1 | 9 | 7 |
P5 | 14 | 16 |
P2 | 33 | 30 |
The average waiting time is ((0 + 2 + 7 + 16 + 30) / 5) = 11 milliseconds
For RR the jobs would execute as follows
Process | CPU Time |
P1 | 8 |
P2 | 8 |
P3 | 2 |
P4 | 5 |
P5 | 8 |
P1 | 1 |
P2 | 8 |
P5 | 6 |
P2 | 8 |
P2 | 8 |
P2 | 1 |
The waiting time for each process is as follows
P1 : 0 + 23 = 23
P2 : 8 + 16 + 6 = 30
P3 : 16
P4 : 18
P5 : 23 + 9 = 32
Therefore, the average waiting time is ((23 + 30 + 16 + 18 + 32) / 5) = 23.80
· Courtois P., J., Heymans F. and Parnas D. L. 1971. Concurrent Control with Readers and Writers. Communications of the ACM, Vol. 10, pp. 667-668
· Dijkstra E. W. 1965. Co-operating Sequential Processes. Programming Languages, Genuys, F. (ed), London :Academic Press
· Peterson G., L. 1981. Myths about the Mutual Exclusion Problem. Information Processing Letters, Vol 12, No. 3
· Silberachatz A., Galvin P. 1994. Operating System Concepts (4th Ed). Addison-Wesley Publishing Company
· Tanenbaum, A., S. 1992. Modern Operating Systems. Prentice Hall.
Last Page Back to Main Index Next Page
Last Updated : 23/01/2002