10.7. Homework - Memory ManagementΒΆ

Due April 17.

  1. Suppose a process has the following memory page reference stream: 3, 2, 4, 3, 4, 2, 2, 3, 4, 5, 6, 7, 7, 6, 5, 4, 5, 6, 7, 2, 1
    1. Given a page frame allocation of 3 and assuming the primary memory is initially unloaded, how many page faults will occur with Belady’s optimal algorithm?
    2. Given a page frame allocation of 3 and assuming the primary memory is initially unloaded, how many page faults will occur with LRU?
    3. Given a page frame allocation of 3 and assuming the primary memory is initially unloaded, how many page faults will occur with FIFO?
    4. Given window size of 5 and assuming the primary memory is initially unloaded, how many page faults will occur with the working-set frame allocation scheme? Show the number of frames allocated at each page reference.
  2. In a paging system, page boundaries are transparent to the programmer. Explain how a loop might cause thrashing in a static allocation paging system when the memory allocation is too small.