Question

Consider a process executing on an operating system that uses demand paging. The average time for a memory access in the system is M units if the corresponding memory page is available in memory, and D units if the memory access causes a page fault. It has been experimentally measured that the average time taken for a memory access in the process is X units.

Which one of the following is the correct expression for the page fault rate experienced by the process?

Choose one option
Official answer and solution
Official answer
B
From
Official GATE 2018 answer key

Solution

Express effective memory access time as a weighted average and solve for page fault rate.

Let pp denote the page fault rate. Then 1−p1 - p is the probability that a memory access hits in memory without a fault.

The expected access time XX is given by:

X=(1−p)M+pDX = (1 - p)M + pD

Expand and rearrange:

X=M−pM+pD=M+p(D−M)X = M - pM + pD = M + p(D - M)
X−M=p(D−M)X - M = p(D - M)
p=X−MD−Mp = \frac{X - M}{D - M}
Final answer

B

The answer is the one in the official GATE answer key. The solution is this site's own explanation.

Source

Paper
GATE 2018 Computer Science and Information Technology (CS)
Question
20 of 65, printed as CS Q.10
Section
Computer Science and Information Technology

Report an error in this question

GATE questions are the work of the organising institutes. This site is independent and is not affiliated with them.