| OCR Text |
Show fork. Since they do not want to give up the forks they already hold, they can wait an arbitrary long amount of time. Solutions to the dining philosophers problem include special protocols to reach agreement among philosophers or the introduction of a servant. In the first case, protocols place cognitive load on philosophers. Therefore, they are not as effective at thinking as without these protocols. On the other hand, philosophers are not happy with the servant either. They must follow the directions of the servant and they feel restricted in their freedom. Solutions with protocols or servants impose overhead on philosophers. This overhead is paid every time when a philosopher takes a fork, even if there is no danger of a deadlock. Introspection provides a solution that imposes the overhead only in the case of a deadlock. Philosophers are allowed to act freely without any consideration for a deadlock. Occasionally, an invisible, omniscient master surveys philosophers. If the master detects a deadlock, enough philosophers are put to sleep to resolve the deadlock. Forks fall from the hands of sleeping philosophers and they are free to be picked up by awake philosophers. When the danger of a deadlock passes the master puts forks in the hands of sleeping philosophers and wakes them up. The problem of deadlocks is resolved to everyone's happiness. Complicated protocols can be wrong or poorly understood, and servants can be bribed easily. But invisible, omniscient master is hidden. Philosophers are not aware of the master and they happily live forever. D ea d lo ck in C om p u te r Systems What is the difference between a servant and an omniscient master? The most important difference is that the actions of a servant are seen by philosophers and the protocol to deal with the servant in determined in advance. In a computer system, a servant corresponds to an operating system or a server. Processes must use them in a prescribed way. But an omniscient master cannot be perceived by 31 |