• edited by
18,623 views
46 46 votes

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.

  1. $(D-M) /( X-M)$
  2. $(X-M) /( D-M)$
  3. $(D-X) / (D-M)$
  4. $(X-M) /( D-X)$

4 Answers

Best answer
98 98 votes

Let $P$ be the page fault rate.

Average memory access time $= ( 1 -$ page fault rate$) \times$ memory access time when no page fault  $+$  Page fault rate  $\times$ Memory access time when page fault.

$X = (1-P) M + P \ D$

$X = M + P( D - M)$

$P = (X - M) / ( D - M)$

(B) is the answer.

• edited by
2 2 votes

The average memory access time is m when no page fault and d when page fault

X = (1-p)m + p(d)

 

upon solving

 

$\frac{x-m}{d-m}$ is the answer

2 2 votes
if not page fault rate = p

so page fault rate =1-p

then  X= P* M + (1-P)*D
  P=X-D/M-D
1-P = 1 – (X-D/M-D ) =M-X/M-D = X-M/D-M = page fault rate
0 0 votes

Given that,

Average memory access time when page fault does not occur = M

Average memory access time when page fault occurs = D

Effective memory access time = X (experimentally calculated)

Let the page fault rate be P.

We know that when page faults are possible

Effective memory access time = (1 - Page Fault Rate) x (Average memory access time without page fault) + (Page Fault Rate) x (Average memory access time with page fault)

X = (1-P) x M + P x D

X = M - P.M + P.D

X = M + P.D - P.M

X = M + P x (D-M)

P x (D-M) = X-M

P = (X-M) / (D-M)

Answer: Option B✅
Answer:
Position:
Show:

Related questions

52 52 votes
9 answers 9 answers
26.4k
26.4k views
gatecse asked Feb 14, 2018
26,354 views
Consider the following solution to the producer-consumer synchronization problem. The shared buffer size is $N$. Three semaphores $empty$, $full$ and $mutex$ are defined ...
43 43 votes
4 answers 4 answers
25.0k
25.0k views
gatecse asked Feb 14, 2018
25,008 views
In a system, there are three types of resources: $E, F$ and $G$. Four processes $P_0$, $P_1$, $P_2$ and $P_3$ execute concurrently. At the outset, the processes have decl...
40 40 votes
4 answers 4 answers
17.9k
17.9k views
gatecse asked Feb 14, 2018
17,859 views
The following are some events that occur after a device controller issues an interrupt while process $L$ is under execution.P. The processor pushes the process status of ...
51 51 votes
7 answers 7 answers
27.3k
27.3k views
gatecse asked Feb 14, 2018
27,346 views
A six sided unbiased die with four green faces and two red faces is rolled seven times. Which of the following combinations is the most likely outcome of the experiment?T...