CS 322 Fall 2013
Project 6
Virtual Memory
Due Tuesday, December 10th at 10:00 P.M.

The goals of this project are

You may work in groups of two. Collaboration within a group is, of course, unrestricted.
You may discuss the program with members of other groups, but what you turn in must be your own group's work.

It is a violation to the Honor Code not to acknowledge others' work fully and openly.
You should cite any online resources you consulted to help you solve this project.
You may NOT directly copy any code or any text from anywhere.

Setup

Copy the files in the directory on royal
/Shared/cs322/public/project6

Simulation

Write a program that simulates the following four page replacement algorithms

  1. OPT (optimal),
  2. FIFO,
  3. LRU and
  4. Second-Chance (aka Clock).

The program can either

The program reports the number of page faults that occur while processing the entire reference string, using pure demand paging.

Analysis

For the following page reference string,

0 1 2 0 1 2 1 2 2 0 3 4 5 4 5 6 5 6 6 5 5 4 4 5 6 5 6 5 7 6 7 7 7 6 6 7 6 7 7 6 5 3 3 4 3 4 3 4 2 3 3 4 3 7 6 6 7
run the 4 algorithms, recording the number of page faults that occur for each of frames of memory.

Draw graph(s) (using Excel, OpenOffice Spreadsheet...) showing how each algorithm performs with the given reference string.

If possible, graph all 4 algorithms in the same chart.

Discuss the results of this experiment in your readme. In particular, answer, with reasons, the following questions.

Submit

Please submit a directory named by your two first names by the deadline on royal
		/Shared/cs322/submit/proj6
It must contain

Grading

This project is graded out of 20 points.

code
12
graph
3
readme
5