Virtual Memory

Cleaning Policy

The cleaning policy determines when a modified page should be written out to secondary memory.

There are 2 common alternatives:

  1. Demand Cleaning
  2. Pre-cleaning

Demand cleaning (parallel with Demand Paging)

  • A page is written out only when it has been selected for replacement
  • Requires two page transfers per page fault

Pre-cleaning (parallel with Prepaging)

  • Pages are written out in batches
  • Allows bursty long (large block) I/O
  • … but write may be unnecessary

Best approach uses Page Buffering.