Thrashing

When an application constantly swapping pages in and out

  • Very slow

Cause

  • Process requires more memory than system has
    • Each time a page is brought in, a page that will need to used later is evicted
  • Memory access pattern does not exhibit temporal locality

Approach 1: Working Set Model

According to 80⧸20 Rule, some portion of the address space will be heavily used and the remainder will not.

Given locality of reference, how big a cache does the process need?

Only run processes whose memory requirement can be satisfied

Approach 2: Page Fault Frequency

PFF = page faults / instructions executed