SRPT Algorithm - Operating Systems and System Programming - Exams, Exams of Operating Systems

Main points of this exam paper are: Srpt Algorithm, Defined Metric, Metric, Plausible Manner, Realistic System, Allocated Memory, Virtual Memory, Memory Schemes, Provide Protection, Resource Allocations

Typology: Exams

2012/2013

Uploaded on 04/02/2013

shailesh_pr1c
shailesh_pr1c 🇮🇳

4.7

(7)

60 documents

1 / 7

Toggle sidebar

This page cannot be seen from the preview

Don't miss anything!

bg1
1
CS 162, Spring, 2007
Prof. Alan Jay Smith
Midterm 1, Wednesday, February 28, 2007
1. Within the implementation of P & V, we used both Test and Set and Disable
Interrupts. Why are both used? Is each necessary? Explain. (10)
pf3
pf4
pf5

Partial preview of the text

Download SRPT Algorithm - Operating Systems and System Programming - Exams and more Exams Operating Systems in PDF only on Docsity!

CS 162, Spring, 2007 Prof. Alan Jay Smith Midterm 1, Wednesday, February 28, 2007

  1. Within the implementation of P & V, we used both Test and Set and Disable Interrupts. Why are both used? Is each necessary? Explain. (10)
  1. In class, it was stated that the SRPT algorithm was optimal according to a specific and well defined metric.

A. What is the SRPT algorithm and how does it work? (6)

B. By what metric is it optimal? (6)

C. Explain in some plausible manner (don’t try to give us any sort of mathematical proof) why it is optimal according to the metric. (6)

  1. Given the following processes and their resource allocations, use the banker’s algorithm to determine if a deadlock is inevitable; show your calculations. The system has 10 units of X and 15 units of Y. (12)

Process has_X max_need_X has_Y max_need_Y 1 3 10 2 4 2 0 6 6 7 3 5 5 2 6 4 1 2 5 5

  1. State and explain the four conditions for deadlock. (16)
  1. Suppose that your program Zork calls a separately compiled procedure Biff at an entry point called Snick. Explain why the reference within Zork to Snick needs help from the linker/loader to work correctly. Explain (in as much detail as necessary) what the linker/loader must do to make this work correctly. (Specify any necessary information that must be provided in the load modules (i.e. the compiler output) for Zork and Biff.) Discuss any necessary tables. (14)