Deadlock

Deadlock

The Dining Philosophers program deadlocks when every philosopher has obtained his/her right chopstick. No philosopher can obtain his/her left chopstick and so no progress can be made. The system is deadlocked.

A thread/process is said to be in a deadlock state if it is waiting for a condition that will never become true (e.g. left chopstick becoming free).

Note that the potential for deadlock exists independently of the thinking and eating times. However, the probability of deadlock occurring increases as these times are reduced.

Previous slide Next slide Back to the first slide View Graphic Version