Question: Q 1 2 [ 4 pts ] Assume that processes P 1 , P 2 , P 3 , P 4 , and P 5

Q12[4pts] Assume that processes P1, P2, P3, P4, and P5 arrive at the system at the same time in that
order and P1 is scheduled to run. The rest are in ready state waiting for the CPU. Assume that First Come
First Served scheduling is used and there are three semaphores S1, S2, and S3. Initial values of all the
semapores are 0.
(a)[2pts] What will be the values of S1 and S2 after the following sequence of actions
P1 does down(S1)
P2 is scheduled and does down(S2)
,P3 is schedule and does up(S1)
P4 is scheduled and does up(S1) followed by a down(S2)
(a)[2pts] What would be the content of the blocked queue after the actions listed in (a)?
Q 1 2 [ 4 pts ] Assume that processes P 1 , P 2 ,

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!