Consider five processes, P0,P1,P2,P3,P4 and three resources A,B,C.Given below are the maximum needs and currently allocated resources to these processes.
|
|
Max needs |
Currently Allocated |
||||
|
|
A |
B |
C |
A |
B |
C |
|
P0 |
7 |
5 |
3 |
0 |
1 |
0 |
|
P1 |
3 |
2 |
2 |
2 |
0 |
0 |
|
P2 |
9 |
0 |
2 |
3 |
0 |
2 |
|
P3 |
2 |
2 |
2 |
2 |
1 |
1 |
|
P4 |
4 |
3 |
3 |
0 |
0 |
2 |
Total resources->A-10; B 5; C 7
What is the safe sequence?
1
P2 P3 P2 P4 P0
2
P0 P1P3P4P2
3
P1P0P2P4P3
4
P3P1P4P0P2