D Question 11 5.25 pts Consider the fallowing resource allocation graph, defined
ID: 3910996 • Letter: D
Question
D Question 11 5.25 pts Consider the fallowing resource allocation graph, defined as in section 7.2.2: Gs(P.R E·P-IP1.P2.P3.P41 R:IR1,R2.R31, E?P1 ? R1. P2-R2. P2 ? Ra. P4 ? R3, R1 ? P2. R2-P3. R2 ? P4, R3 ? P1, R3 P3. All resources are of the same type. Which of the tollowing sentences is true about the system described? has 2 cycles and is desadlocked O has 1 cycle and is not deadlocked O has 2 cycles and is not deadlocked O has 1 cycle and is deadlocked D Question 12 5.25 pts In the Dining Philosaphers solutian with semaphores deadock occurs if all five philosophers pick their right chapstick at the same time. The solution with manitars maloes the philosophers pick up both chopsticks at once in an atomic sequence) and only if both are available. Which of the 4 deadlock conditions does the monitor solution eliminate? mutual cxlusion O no preemption cirtuer wat D Question 13 5.25 pts How is Lhe methad of breaking the 'hold and wait deadlock condition similar with breaking Lhe "preemption condition for deadlock prevention? both methods rely on a process knowing beforehand what resources it will need in the future D both methods may lead to starvation O both methods may forte ? process to wait for all resources it needs before it can start neither actuzlly provents dloalock when used aloneExplanation / Answer
11. the correct option is D. This system has 1 Cycle and is deadlocked
which is P1 -> R1 -> P2 -> R2 -> P4 -> R3 -> P1 . P1 is requesting resources from R1 and P2 is asking resources from R1 and P2 is requesting resources from R2 and P4 is asking resources from R2 and P4 is requesting resources from R3 and hence P1 is indeed asking resources from R1.
12. the correct option is A. Monitor solution eliminates the hold-and-wait deadlock condition
Monitors partially use this technique to avoid hold-and-wait, calling wait on a variable condition will release the lock, so that acquiring the monitor lock cannot cause deadlock.
13. the correct option is - C. Both methods rely on a process knowing beforehand what resources it will need in the future, this knowledge in advance is often difficult to satisfy and an inefficient use of resources may happen.And also a process requiring a popular resource may have to wait indefinitely, as such a resource may always be allocated to some process, may result in resource starvation.
Related Questions
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.