adplus-dvertising
frame-decoration

Question

Consider the methods used by processes P1 and P2 for accessing their critical sections whenever needed, as given below. The initial values of shared boolean variables S1 and S2 are randomly assigned.

Method used by P1 :
while(S1==S2);
Critical section
S1 = S2;

Method used by P2 :
while(S1!=S2);
Critical section
S2 = not(S1);

Which of the following statements describes properties achieved ?

a.

Mutual exclusion but not progress

b.

Progress but not mutual exclusion

c.

Neither mutual exclusion nor progress

d.

Both mutual exclusion and progress

Posted under Operating System

Answer: (d).Both mutual exclusion and progress

Engage with the Community - Add Your Comment

Confused About the Answer? Ask for Details Here.

Know the Explanation? Add it Here.

Q. Consider the methods used by processes P1 and P2 for accessing their critical sections whenever needed, as given below. The initial values of shared boolean variables S1 and S2 are...

Similar Questions

Discover Related MCQs

Q. Which of the following concurrency control protocols ensure both conflict serializability and freedom from deadlock ?

I) 2-phase locking
II) Time-stamp ordering

Q. The initial value of the semaphore that allows only one of the many processes to enter their critical sections, is

Q. For how many processes which are sharing common data, the Dekker's algorithm implements mutual exclusion?

Q. Semaphores

Q. What is the initial value of the semaphore to allow only one of the many processes to enter their critical section?

Q. Part of a program where the shared memory is accessed and which should be executed invisibly, is called

Q. A critical region is

Q. For procedure, the system prevent the overlap of buffer

Q. In implementation of Semaphores, for a single processor system, it is possible to inhibited

Q. In message passing a process receives information by executing the

Q. In a uniprocessor system concurrent processes cannot have overlapped

Q. In addressing, a many to one relationship is useful for

Q. The controller process services writes a

Q. Using Semaphores, each process has a critical section used to access the

Q. The global variable read count is used to keep the track of the number of

Q. In readers/writers problems, Readers are processes that are not required to

Q. Requirement for mutual exclusions a process remains inside its critical section for a

Q. For synchronization, the communication of a message between two processes implies some level of

Q. The operating system must allocate and deal various resources for each active

Q. During process interaction concurrent processes come into conflict with each other when they are