Problem based on banker''s algorithm, Computer Engineering

Assignment Help:

A system contains 10 units of resource class Ru. The resource requirements of three user processes P1, P2 and P3 are as follows

                                                P1                  P2                P3

Maximum requirements          8                     7                   5

Current allocation                   3                     1                   3

Balance requirements            5                     6                   2

New request made                 1                     0                   0

Using Banker's algorithm, determine if the projected allocation state is safe and whether the request of P1 will be granted or not.

From the specified data: Total_alloc=[7] Total_exist=[10]

The projected allocation state is feasible as the total allocation into this does not exceed the number of resource units of Ru. Because P3 is two units short of its maximum requirement and two unallocated unit exits into the system, therefore P3 can complete. It will release the resources allocated to this, i.e., 5 resources. Here P1 can complete as the number of unallocated units of Ru exceeds the units required to satisfy its maximum requirement then P2 can be finished.

Therefore the processes can complete in the sequence P3, P1, and P2. Therefore projected allocation state is safe thus algorithm will grant the request made through P1.


Related Discussions:- Problem based on banker''s algorithm

How does the race condition occur, It happens when two or more processes ar...

It happens when two or more processes are reading or writing some joint data and the final result depends on who runs exactly when.

Returns information about present virtual machine, Q. Returns information a...

Q. Returns information about present virtual machine? int pvm_parent( void ) Returns the tid of process which spawned the calling process.  int pvm_tidtohost(

State the important features of operating system, a. Define operating syste...

a. Define operating system? State the important features of operating system? b. Describe the following facilities for implementing interacting processes in programming language

What is a snooping cache, DNS cache snooping is not a term the author just ...

DNS cache snooping is not a term the author just made up, it is called and discussed by some notable DNS execution developers, and a few interested DNS administrators have prob

What is the impact of overflow for binary numbers, Q. What is the impact of...

Q. What is the impact of overflow for binary numbers? An overflow is said to have happened when sum of two n digits number takes n+ 1 digits. This definition is perfectly appli

Give the example of first come first served scheduling, Consider  the  foll...

Consider  the  following set of jobs with  their  arrival  times,  execution  time  (in minutes), and deadlines. Job Ids Ar r ival Time E

Interpeter, diifference between pure and impure interpeter

diifference between pure and impure interpeter

Where virtual memory is used, Where Virtual memory is used ? Ans. Virtu...

Where Virtual memory is used ? Ans. Virtual memory is utilized in all main commercial operating systems.

Explain the working of a 3-bit D/A converter, With the help of R-2R binary ...

With the help of R-2R binary network, explain the working of a 3-bit D/A converter and derive an expression for the output voltage. Ans: We see a 3-bit R-2R ladder D/A netwo

Internal conditioning, types of internal conditioning with explanations and...

types of internal conditioning with explanations and examples

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