888 views
0 votes
0 votes

Original Question - https://gateoverflow.in/8405/gate2015-3-10

 

Answer is A) Yes, there's no ME (That's fine) 

Also there's no Deadlock, but for no deadlock, can we give reason as - 

 

There's no deadlock, because there's no circular wait as both processes X and Y are working on different sets of shared variables. 

X on varP and Y on VarQ. So, there's no dependency there. 

 

And hence No deadlock? Is this reasoning for deadlock valid?

1 Answer

1 votes
1 votes
ANSWER is B ,because when both the shared variables are True then the system will come in deadlock but it ensures  the mutual exclusion.

Related questions

3 votes
3 votes
0 answers
3
iarnav asked Sep 28, 2018
720 views
Any implementation of a critical section requires the use of an indivisible machine- instruction ,such as test-and-set?Is the above statement True or False?