GATE CS 2022 | Question 26

Operating Systems › Deadlock · MSQ · 1 mark · Answer: A, D

  1. Question 26Operating Systemsmsq1 mark
    Which statements about deadlocks are TRUE?
    • A.
      Circular wait is a necessary condition for deadlock.
      ✓
    • B.
      If each resource has more than one instance, a cycle in the wait-for graph indicates a deadlock.
    • C.
      If current allocation leads to an unsafe state, deadlock will necessarily occur.
    • D.
      If every edge in the resource-allocation graph is an assignment edge, the system is not in deadlock.
      ✓

    Answer: A, D

    Solution

    Answer: (A) and (D) - (A) Circular wait is one of the four necessary (Coffman) conditions for deadlock. True. - (D) If every edge is an assignment edge (no process is waiting/requesting), no process is blocked, so no deadlock. True. - (B) False: with multiple instances, a cycle is necessary but not sufficient for deadlock. - (C) False: an unsafe state may lead to deadlock but does not guarantee it.

More GATE PYQ on Deadlock

All GATE CS Operating Systems PYQ →

Attempt GATE CS 2022 in real GATE exam mode

Full paper with a timer, the GATE interface and a topic-wise analysis — free.

Create free account →