GATE CS 2016, set 2 · Question 58 · Operating System · Multiple choice (MCQ) · 2 marks · −2/3 for a wrong answer

Consider the following two-process synchronization solution.
Process 0 --------- Entry: loop while (turn == 1); (critical section) Exit: turn = 1; Process 1 ---------- Entry: loop while (turn == 0); (critical section) Exit: turn = 0;
The shared variable turn is initialized to zero. Which one of the following is TRUE ?

  1. (A) This is a correct two-process synchronization solution.
  2. (B) This solution violates mutual exclusion requirement.
  3. (C) This solution violates progress requirement.
  4. (D) This solution violates bounded wait requirement.
Answer

Answer (C)

Answer from the official GATE CS 2016 answer key.

The step-by-step solution, where available, is part of GATE CS Pro. See what Pro includes