Q17.Marks: +2.0UGC NET Paper 2: Computer Science17th June 2023
Given below are two statements: one is labelled as Assertion A and the other is labelled as Reason R.
A virtual memory system uses first-in first-out page replacement policy and allocates a fixed number of frames to a process
Assertion A: Increasing number of page frames allocated to a process sometimes increases the page fault rate.
Reason R: Some programs do not exhibit locality of reference.
In the light of the above statements, choose the correct answer from the options given below.
1.Both A and R are true and R is the correct explanation of A
2.Both A and R are true but R is NOT the correct explanation of A✓ Correct
3.A is true but R is false
4.A is false but R is true
Solution
The correct answer is Both A and R are true but R is NOT the correct explanation of A
Key Points
Assertion A is true because of the phenomenon known asBelady's Anomaly -
In some instances, increasing the number of page frames may result in an increased page fault rate.
This unexpected result typically has to do with the specific page replacement algorithm being used not always behaving the way you'd expect as more and more page frames are added.
In this case, the algorithm mentioned is First-In-First-Out (FIFO).
Reason R is also true, because some programs do not exhibit locality of reference.
Locality of reference means that programs tend to request pages which are related to the pages they have already requested, or are likely to request pages they have requested recently. Not all programs follow this pattern.
However, R is not the correct explanation of A. Belady's Anomaly isn't caused by a lack of locality of reference, rather it is related to the particular nuances of the replacement algorithm in question (in this case, FIFO). So while both statements are true, they aren't connected in the way the question implies. Hence the answer is option 2.