Operating System Deadlocks Circular Wait

Asked By 0 points N/A Posted on -
qa-featured

I know that there are 4 conditions that could cause deadlocks, but I'm stuck with the circular wait. I am confused about its algorithm or how it is achieve.

All I want to know is, if there is a diagram that could explain better or could give a keen details about deadlocks circular wait.

SHARE
Answered By 75 points N/A #96146

Operating System Deadlocks Circular Wait

qa-featured

Hi Jimmy Karl,

The circular wait algorithm processes are required to access or use a resource a particular order, so that when one process is done using a resource, the next process in the queue takes the resource, uses it after which it will give to the next waiting process in queue and the sequence continues.

Assuming you have three process named A, B and C and they have to use a resource in a manner that circular wait will be implemented, process A will take the resource and use it for a considerable amount of time and when it is done process B will take the resource and use it for a considerable amount of time and then hand the resource to process C. Process C will hand the resource to A after it is done with it, and the process continues that way.

A deadlock may occur if one process decides to use the resource forever, and that is why there should a time allocation that a process can use the resource.

Hope this helps.

Regards,

Lee Hung.

Related Questions