Ask Question
21 December, 13:49

Consider a system consisting of m resources of the same type, being shared by n processes. Resources can be requested and released by processes only one at a time. Show that the system is deadlock free if the following two conditions hold:

A. The maximum need of each process is between 1 and m resources

B. The sum of all maximum needs is less than m+n.

+3
Answers (1)
  1. 21 December, 17:38
    0
    A=Sum of all needs

    B=Sum of all allocations

    C=Sum of all max need

    Let's say that our system is not deadlock free right now. If the system is in deadlock then sum of all allocations should be equal to the total number of resources i. e. B = m

    Now the statement (b) says that sum of all maximum needs is less than m + n i. e. A + B = C < m + n.

    As from above deduction B = m so, A + m < m + n

    or A < n, which means that there is one process for which need it zero as number of processes it greater than need and a process can request and release only one resource at a time. So, there are n-1 processes sharing m resources currently. But no process will wait permanently, hence there is a contradiction and there is no deadlock.
Know the Answer?
Not Sure About the Answer?
Find an answer to your question ✅ “Consider a system consisting of m resources of the same type, being shared by n processes. Resources can be requested and released by ...” in 📘 Computers and Technology if you're in doubt about the correctness of the answers or there's no answer, then try to use the smart search and find answers to the similar questions.
Search for Other Answers