317 views

1 Answer

0 votes
0 votes
1. mutual exclusion is not satiefied over here . suppose take process p1 and p2 , p1 reads the occupied =0 and preemts now p2 enter and read the value of occupied =0  they both made occupid =1 and enter into critical section.

2. Progress is not satisfied. p1 enter into critical section tafter that it executes exit section before it doing anthing it preempts and p2 trying to enter into critical section , it reads occupied=1 and enter into if block and do blocked++ and preempts again , p1 resumes again and make occupied=0 andblocked--   and call wakeup the sleeping process but there is not any process sleeping. Now p1 can enter into critical section any number of times, same way another n numbers of process can enter into critical section without giving chance to p2 this possible when blocked is not updated.

Related questions

1 votes
1 votes
0 answers
1
shefaligups11 Gups asked Nov 8, 2016
586 views
0 votes
0 votes
2 answers
2
shefaligups11 Gups asked Nov 8, 2016
390 views
2 votes
2 votes
1 answer
4
KISHALAY DAS asked Nov 3, 2016
361 views