1,720 views
3 votes
3 votes
Which of the following is true?
S1: If there is a cycle in RAG then there will be a deadlock
S2: If there is a cycle in RAG where all the resources are havinng single instance then there will be a deadlock
S3: Unsafe state results in deadlock
S4: Deadlock states is subset of unsafe states

(A) S4 only
(B) S2 & S4 only
(C) S1 & S4 only
(D) S1, S3 & S4 only

3 Answers

Best answer
6 votes
6 votes

S1. False. for some  Multi-instance resources

Here in below fig. cycle is there but no deadlock

S2.True . bcz corresponding Wait-for-graph have a cycle (Here it is single instance resource)

Note:-The wait-for-graph scheme is not applicable to a resource allocation system with multiple instances of each resource type.

S3. False & S4.True :-Reason

Galvin IMG :-

Hence B is Ans.

selected by
0 votes
0 votes

S1 is wrong because Cycle Is Necessary Condition But not Sufficient Condition In Multi Instance Graph For Deadlock.

S2 Is Right Because Cycle Is Necessary As well As Sufficient Condition In Single Instance Graph For Deadlock.

S3 Is wrong And S4 Is Right because

Dead lock Is a subset of Unsafe State , it means that If the System is in Deadlock It will necessary In the Unsafe state but it does not mean that if system is in unsafe state then it is definitely deadlock state

So, Option B is Right.

Related questions

0 votes
0 votes
1 answer
1