Thursday, August 27, 2009

Resource - allocation Graph
> A set of vertices and a set edges E.

- V is partition into two types:
P={P1,P2,...Pm}, the set consisting all the processes in the system.
R= {R1,R2,...,Rm}, the set consisting of all resources types in th system.
>request edge-directed edge P1->R1
>assignment edge-directed- directed edge R1 ->P1

Resource allocation graph (cont.)

> Process




>resource type with 4 instances

>P1 is request an instance of R1

>P1 is holding an instance of R1


Example of Resource allocation Graph




process 1 request instances of resource 1
resource 1 is holding an instances of process 2
process 2 request instance of resource 3
resource 3 is holding an instance of process 3
resource 2 request instances of process 1 and process
resource 4 is a resource type with 4 instances.




Resource allocation graph With deadlock




















Resource allocation graph with a cycle but no deadlock




















No comments: