 |
 |
 |
 |
 |
 |
 |
 |
 |
 |
 |
 |
 |
 |
 |
 |
 |
 |
• |
Once
a deadlock is detected, there are 2 choices:
|
|
|
|
1. |
abort
all deadlocked processes (which will cost in the
|
|
|
repeated
computations necessary)
|
|
|
|
2. |
abort
1 process at a time until cycle is eliminated
|
|
|
(which
requires re-running the detection algorithm
|
|
|
after
each abort)
|
|
|
• |
Or,
could do process preemption: release resources until
|
|
|
system
can continue. Issues:
|
|
|
|
– |
selecting
the victim (could be clever based on R’s
|
|
|
allocated)
|
|
|
|
– |
rollback
(must rollback the victim to a previous state)
|
|
|
|
– |
starvation
(must not always pick same victim)
|
|
|
• |
These
are common database inspired methods, within an
|
|
interactive
OS none are really that acceptable
|
|