Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

(25 pts) The following are Request matrix Q and Allocation matrix A that define

ID: 3907539 • Letter: #

Question

(25 pts) The following are Request matrix Q and Allocation matrix A that define the state of a system, as might be used to perform deadlock detection, as well as the Resource vector R which gives the tot al umber of each resource in the system: Q R1 R2 R3 | A R1 R2 R3 |R R1 R2 R3 P 0 0 P0 0 P2 0 0 1P2 00 P3000|P3 In this problem, you are to run the deadlock det ection algorithm on the system state given above. We have not given you the available vector V, but you should be able to det ermine what the current available vector is (it is simply the total mber of resources R mius those that have been allocated to processes, shown in A). Perform the deadlock det ection algorithm by hand. Perform the steps (a) - (d) (looping back to c if/when needed

Explanation / Answer

Total allocated = 1 1 1

Total resources = 2 1 1

Total available = 1 0 0

Request by P1 : This request can be granted as P1 is requesting for 1 unit of R1 and it is available.

After this P1 will be completed and release all its resources

New available is 1 0 1

Request by P2: This request also can be granted as now we have 1 UNIT of R3 in available matrix

Request by P3 :Not asking for any resources.

All Processes are in safe state. Hence no dead lock.