adplus-dvertising
frame-decoration

Question

Let S and Q be two semaphores initialized to 1, where P0 and P1 processes the following statements wait(S);wait(Q); ---; signal(S);signal(Q) and wait(Q); wait(S);---;signal(Q);signal(S); respectively. The above situation depicts a _________ .

a.

Semaphore

b.

Deadlock

c.

Signal

d.

Interrupt

Answer: (b).Deadlock

Engage with the Community - Add Your Comment

Confused About the Answer? Ask for Details Here.

Know the Explanation? Add it Here.

Q. Let S and Q be two semaphores initialized to 1, where P0 and P1 processes the following statements wait(S);wait(Q); ---; signal(S);signal(Q) and wait(Q);...

Similar Questions

Discover Related MCQs

Q. The state of a process after it encounters an I/O instruction is __________.

Q. The Banker's algorithm is used

Q. ______ is a high level abstraction over Semaphore.

Q. In one of the deadlock prevention methods, impose a total ordering of all resource types, and require that each process requests resources in an increasing order of enumeration. This voilates the _______________ condition of deadlock.

Q. Banker's algorithm for resource allocation deals with ?

Q. What is the maximum number of processes that may enter simultaneously inside the critical section to avoid race condition ?

Q. What are global locks ?

Q. Semophores are used to solve the problem of

Q. Semaphores function is to

Q. Four necessary conditions for deadlock are non pre-emption, circular wait, hold and wait and

Q. Banker's algorithm deals with

Q. Which of following is not a condition of Dead Lock ?

Q. A solution to the Dining Philosophers Problem which avoids deadlock is 

Q. Let m[0]…m[4] be mutexes (binary semaphores) and P[0] …. P[4] be processes. 
Suppose each process P[i] executes the following: 
  wait (m[i]);wait (m[(i+1) mode 4]); 
  .........
  release (m[i]); release (m[(i+1)mod 4]); 
This could cause 

Q. What are the necessary conditions to occur the deadlock?

Q. Deadlocks can be described by which graph?

Q. Choose the correct option regarding deadlock.

Q. Which of the following is deadlock avoidance algorithm?

Q.  In a graph the number of vertices of odd degree is always

Q. Consider a computer system with 6 tape drives and 'n' processes completing for them. What is the maximum value of 'n' for the system to be deadlock free? (Assuming that each processes may need 3 tape drives)