5 a Explain how to improve the solution to the Readerswriter

5. (a) Explain how to improve the solution to the Readers-writers problem. (b) Why is this not a deadlock problem?

Solution

Clearly the solution gives readers preference over writers; once one reader is accessing the DB , all readers are allowed to read the DB without performing the P or V operations on sWriters .

We cannot say that its not a deadlock problem andmight be we can get a deadlock and solution is Reader-writer deadlock using n+1 semaphore as given below :

//psuedo code

5. (a) Explain how to improve the solution to the Readers-writers problem. (b) Why is this not a deadlock problem?SolutionClearly the solution gives readers pre

Get Help Now

Submit a Take Down Notice

Tutor
Tutor: Dr Jack
Most rated tutor on our site