Past-paper question · 2016 October-November · Paper 32 · Q3(c)(iii)

Question 3(c)(iii) 2016 · October-November · Paper 32 · 3 marks

Question 3

Part (c)

(iii)

Question 3

A computer operating system (OS) uses paging for memory management.

In paging:

  • main memory is divided into equal-size blocks, called page frames
  • each process that is executed is divided into blocks of the same size, called pages
  • each process has a page table that is used to manage the pages of this process

The following table is the incomplete page table for a process, Y.

Page Presence Page frame address Additional data flag 1 1 221 2 1 222 3 0 0 4 0 0 5 1 542 6 0 0

249 0 0 When the next instruction is not present in main memory, the OS must load its page into a page frame. If all page frames are currently in use, the OS overwrites the contents of a page frame with the required page.

The page that is to be replaced is determined by a page replacement algorithm.

One possible algorithm is to replace the page which has been in memory the shortest amount of time.

(iii)

Explain what happens to Page 1 and Page 3, each time the loop is executed.

...........................................................................................................................................

...........................................................................................................................................

...........................................................................................................................................

...........................................................................................................................................

...........................................................................................................................................

......................................................................................................................................

[3]
Reveal official mark-scheme answer Official mark-scheme answer for 3(C)(III)

Official answer for Question 3

Part (c)

(iii)

(iii)

When the procedure call is made – Page 1 is swapped out and Page 3 is swapped in

[1]
✓
At the end of the procedure call – Page 3 is swapped out and Page 1 is swapped in
[1]
✓
Page 1/3 is always in memory shortest amount of time
[1]
✓
The entire sequence is repeated for every iteration
[1]
✓
[Max 3]

Mark scheme 9608_w16_ms_32.pdf →

Topic relevance

Why this question appears here

82% assigned-topic match · Programming › Constructs

Topic-match percentages estimate how closely each question fits the selected syllabus topic. They are a guide for choosing stricter or broader practice.

Permanent source page: Educate A Change · From 9608_w16_qp_32.pdf

Keep practising this topic