Question

Given the following state for the Banker's Algorithm

Given the following state for the Banker's Algorithm 

5 processes PO through P4 

3 resource types before assigning to any process. A has 5 instances: B has 6 Instances. C has 8 instances and D has 4.

image.png

Allocation: the resources currently assigned to each process 

Max Claim: The maximum number of resource instances a process will need in order to complete. 

Determine the available vector


0 0
Add a comment Improve this question Transcribed image text
✔ Recommended Answer
Answer #1

Allocated matrix = (5, 6, 6, 2)

A has 5 instances, B has 6 instances, C has 8 instances, D has 4 instances which is (A, B, C, D) = (5, 6, 8, 4)

Available vector = (5, 6, 8, 4) - (5, 6, 6, 2)

Available vector = (0, 0, 2, 2)

Now calculate need

Need = Max - Allocation

Answer : "yes, p2, p0, p1, p3, p4"

Add a comment
Answer #2

The number of resources allocated are (A, B, C, D) = (5, 6, 6, 2)

A has 5 instances, B has 6 instances, C has 8 instances, D has 4 instances which is (A, B, C, D) = (5, 6, 8, 4)

Available vector = (5, 6, 8, 4) - (5, 6, 6, 2)

= (0, 0, 2, 2)

The answer is (0, 0, 2, 2)

Add a comment
Know the answer?
Add Answer to:
Given the following state for the Banker's Algorithm
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT