1
GATE CSE 1997
MCQ (Single Correct Answer)
+2
-0.6
Each process Pi,i=1.....9 is coded as follows

  Repeat
  P(mutex){
  critical section
  }
  V(mutex)
  Forever
The code for P10 is identical except that it uses V(mutex) in place of P(mutex). What is the largest number of processes that can be inside the critical section at any moment?
A
1
B
2
C
3
D
None of the above
2
GATE CSE 1996
MCQ (Single Correct Answer)
+2
-0.6
A solution to the Dining Philosophers Problem which avoids deadlock is
A
ensure that all philosophers pick up the left fork before the right fork.
B
ensure that all philosophers pick up the right fork before the left fork
C
ensure that one particular philosopher picks up the left fork before the right fork, and that all other philosophers pick up the right fork before the left fork
D
None of the above.
3
GATE CSE 1996
Subjective
+2
-0
The concurrent programming constructs fork and join are as below: Fork (label) which creates a new process executing from the specified label join (variable) which decrements the specified synchronization variable (by 1) and terminates the process if the new value is not 0. Show the precedence graph for S1, S2, S3, S4 and S5 of the concurrent program below.
N = 2
M = 2
fork L3
fork L4
S1
L1 : join N
S3
L2: join M
S5
L3:S2
goto L1
L4:S4
goto L2
next:
4
GATE CSE 1992
MCQ (Single Correct Answer)
+2
-0.6
At a particular time of computation the value of a counting semaphore is 7. Then 20 P operations and 15 V operations were completed on this semaphore. The resulting value of the semaphore is:
A
42
B
2
C
7
D
12
GATE CSE Subjects
Software Engineering
Web Technologies
EXAM MAP
Medical
NEET
Graduate Aptitude Test in Engineering
GATE CSEGATE ECEGATE EEGATE MEGATE CEGATE PIGATE IN
CBSE
Class 12