Professional Documents
Culture Documents
Comprehensive Examination
(EC-2 Regular)
Q.1. Consider the following snap shot of the system of five processes P0 to P4 and 4
resource types, A, B, C and D. The total instances of A, B, C and D in the system
are 10, 8, 18 and 16 respectively.
i. Determine if the system is in the safe state. If yes, give the safe sequence.
ii. If process P1 requests (W, X, Y, Z), then determine the maximum values of
W, X, Y and Z which can be granted without making the state unsafe.
iii. Assume (with initial snapshot) that P4 made a request (0, 0, 1, 2) and this
request was granted. Determine if the system is in safe state and give the safe
sequence if any.
[14]
Q.2. Suppose we have a demand-paged memory. The page table is held in registers. It
takes 8 milliseconds to service a page fault if an empty page is available or the
replaced page is not modified, and 20 milliseconds if the replaced page is
modified. Memory access time is 100 nanoseconds. Assume that the page to be
replaced is modified 70 percent of the time. What is the maximum acceptable
page-fault rate for an effective access time of no more than 200 nanoseconds? [14]
Q.3. A system implements a paged virtual address space for each process using a one
level page table. The maximum size of address space is 16MB. The page table for
running process includes the following entries:
The page size is 1024 bytes and the maximum physical memory size of the machine
is 2 MB.
(a) How many bits are required for each page table entry? What is the maximum
number of entries in a page table?
(b) How many bits are there in a virtual address?
(c) To which physical address will the virtual address 1524 (decimal) translate?
(d) Which virtual address will translate to physical address 10020 (decimal) ?
[14]
Q.4. Explain briefly the factors, which govern the minimum number of frames, which
must be allocated to any process. [6]
Q.5. Suppose that a disk drive has 5000 cylinders, numbered 0 to 4999. The drive is
currently serving a request at cylinder 143, and the previous request was at
cylinder 125. The queue of pending requests in FIFO order is
Starting from the current head position, what is the total distance (in cylinders)
that the disk arm moves to satisfy all the pending requests, for each of the
following disk scheduling algorithms?
(a) FCFS
(b) SSTF
(c) SCAN
(d) C-SCAN
[12]
*******