Week 9
Week 9
Department of Computer
Science
HITEC University Taxila
Chapter 8: Deadlocks
Week-09
Chapter 8: Deadlocks
● System Model
● Deadlock Characterization
● Methods for Handling Deadlocks
● Deadlock Prevention
● Deadlock Avoidance
● Deadlock Detection
● Recovery from Deadlock
System Model
● Ti requests an instance of Rj
T
i
Rj
● Ti is holding an instance of Rj
T
i
Rj
Example of a Resource Allocation Graph
Basic Facts
Need Available
ABC ABC
P0 743 3 3 2
P1 122
P2 600
P3 011
P4 431
● Executing safety algorithm shows that sequence < P1, P3, P4,
P0, P2> satisfies safety requirement