872 views
1 votes
1 votes

does it guarantee mutual exclusion and deadlock prevention? 

2 Answers

0 votes
0 votes

MUTUAL EXCLUSION: Mutual Exclusion means a single process uses the critical Section in mutually Exclusive Manner. and no other process interrupt the critical Section While Other process using it or no process can Enter the Critical Section.

IN THE ABOVE QUESTION: Mutual Exclusion is satisfied  because at the Same time another process if want to enter in the critical Section, the  inner while loop stop for Entering into critical Section

PROGRESS: Progress means when a process is running outside and other processes want to enter in the critical Section than another process should not stop the other process to enter in the critical section

IN THE ABOVE QUESTION, progress does not satisfied hence this can be a deadlock

BOUNDED WAITING TIME: Bounded Waiting time is satisfied here because we know that there is only two process 

0 votes
0 votes
It satisfies mutual exclusion, no progress and satisfies boundary condition. Also there is possiblity of deadlock it these process run concurrently.

Related questions

0 votes
0 votes
1 answer
1
0 votes
0 votes
2 answers
4
shivajikobardan asked Jul 22, 2023
726 views
Sorry if this is a stupid question. But it really intrigued me. Same resources at different algorithms are telling different ways to test these stuffs.Here's an algorith...