This problem demonstrates the use of semaphores to coordinate three types of processes.6 Santa Claus sleeps in his shop at the North Pole and can only be awakened by either (1) all nine reindeer being back from their vacation in the South Pacific, or (2) some of the elves having difficulties making toys; to allow Santa to get some sleep, the elves can only wake him when three of them have problems. When three elves are having their problems solved, any other elves wishing to visit Santa must wait for those elves to return. If Santa wakes up to find three elves waiting at his shops door, along with the last reindeer having come back from the tropics, Santa has decided that the elves can wait until after Christmas, because it is more important to get his sleigh ready. (It is assumed that the reindeer do not want to leave the tropics, and therefore they stay there until the last possible moment.) The last reindeer to arrive must get Santa while the others wait in a warming hut before being harnessed to the sleigh. Solve this problem using semaphores.
Answer to relevant QuestionsShow that message passing and semaphores have equivalent functionality by a. Implementing message passing using semaphores. b. Implementing a semaphore using message passing. Consider the following ways of handling deadlock: (1) Banker’s algorithm, (2) Detect deadlock and kill thread, releasing all resources, (3) Reserve all resources in advance, (4) Restart thread and release all resources ...Show how each of the techniques of prevention, avoidance, and detection can be applied to Figure. In the THE multiprogramming system, a page can make the following state transitions: 1. Empty S input buffer ........ (Input production) 2. Input buffer S processing area ...... (Input consumption) 3. Processing ...What is the difference between a page and a segment?
Post your question