Determine the current allocation state and granted process, Computer Engineering

Assignment Help:

An operating system contains 3 resource classes. The number of resource units in these classes is 7, 7 and 10. The current resource allocation state is shown below:

 

Processes

Allocated resources

Maximum requirements

R1

R2

R3

R1

R2

R3

P1

2

2

3

3

6

8

P2

2

0

3

4

3

3

P3

1

2

4

3

4

4

(i) Is the current allocation state safe?

(ii) Can the request made by process P1 (1, 1, 0) be granted?

(i) In the specified question,

Available  matrix  for  resources  [R1  R2  R3]  =  No  of  resource  unit  - Total Allocation

= [7 7 10]-[5 4 10] = [2 3 0]

Need matrix is identified as (Max - Allocation),

Processes

Need of resources

R1

R2

R3

P1

1

4

5

P2

2

3

0

P3

2

2

0

By using Safety Algorithm, we find sequence:

Processes

Available resources

after satisfying need

R1

R2

R3

2

3

0

P2

4

3

3

P3

5

5

7

P1

7

7

10

The sequence < P2, P3, and P1 > satisfies the safety criteria. Therefore current allocation state is safe.

(ii) Request made through process P1, Request (P1) = [1 1 0] Here, Request (P1) < Need (P1) < Available

That is [1 1 0]< [1 4 5] < [2 3 0]

Pretending such request can be fulfilled, we find new state:

Processes

Allocation

Need

Available

R1

R2

R3

R1

R2

R3

R1

R2

R3

P1

3

3

3

0

3

5

1

2

0

P2

2

0

3

2

3

0

P3

1

2

4

2

2

0

Because Need > Available for all process, no need can be fulfilled therefore allocation is not thread safe that is request made through Process P1 can't be granted.


Related Discussions:- Determine the current allocation state and granted process

What are the different phases of consumer mercantile model, What are the di...

What are the different phases of consumer mercantile model? There are three different phase of consumer mercantile model like listed as in below: • Pre-purchase interaction

C LANGUAGE PROGRAMME, find a c program to find the area under the curve y=f...

find a c program to find the area under the curve y=f(x) between x=a and x=b,intregrate y=f(x)between the limits of a and b.the area under a curve between two points can be found b

Other equivalences, Equivalences: In this following miscellaneous equi...

Equivalences: In this following miscellaneous equivalence rules are often useful during rewriting sessions. So there the first two allow us to completely get rid of implicatio

Explain about the functionality of olap, Hyper cube or multidimensional cub...

Hyper cube or multidimensional cube forms the core of OLAP system. This having of measures which are arranged according to dimensions. Hyper cube Meta data is formed by star or sno

Add the equation by using 2's compliment, Add 20 and (-15) using 2's comple...

Add 20 and (-15) using 2's complement ? Ans. Addition of 20 and (-15) by using 2's complement as (20) 10 = 1 0 1 0 0                                                  (16

What are the concerns for growth of e-commerce in india, What are the conce...

What are the concerns for growth of e-commerce in India?  Government as Facilitator for the growth of e-commerce has taken certain steps: Promotion of competitive teleco

Define router, A router is used to Distributes information among networ...

A router is used to Distributes information among networks.

External program components, How does the system handle roll areas for exte...

How does the system handle roll areas for external program components? Transactions run in their own roll areas. Reports run in their own roll areas. Dialog modules run

Why gateways are used during mail transfer, Why Gateways are used during ma...

Why Gateways are used during mail transfer? Email using SMTP effort best while both the sender and the receiver are on the internet and can hold TCP connections in between send

What is normal form, What is normal form? A normal form is a guideline ...

What is normal form? A normal form is a guideline for relational database tables that enhances data consistency. As tables satisfy higher levels of normal forms, they are less

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd