Deadlock prevention
• Attack mutual exclusion– we always want to minimize the number ofnon-sharable resources, but it is notusually possible to eliminate all of them.
• Attack the no preemption condition– cannot usually take a resource away froma process.
• Attack hold and wait
– require each process to request and beallocated all resources before it beginsexecuting
– before requesting a new resource releaseall locks on other resources and reacquire
– Problems: low resource utilization,starvation
• Attack circular wait.
– This is where most of the effort ofdeadlock prevention is focused.
– Design a hierarchy of lock acquisition suchthat there are no cycles.
– A great idea in theory, but difficult toimplement in practice because theunderlying code does not usually follow anacyclic hierarchy.
Thursday, August 20, 2009
DEADLOCK
Subscribe to:
Post Comments (Atom)

0 comments:
Post a Comment