CS740 Final Project - Milestone Report

Dan Blandford and Takayuki Osogami
({dkb1, osogami}@cs.cmu.edu)
Major Changes

The most significant change that has occurred was in our method of inserting GUARD instructions into the test code. Initially we planned to do this by altering the SimpleScalar compiler. Unfortunately, we were unable to compile the SimpleScalar compiler (much less modify it or use it to compile benchmark code). Fortunately we found a workaround: in the simulator itself we can replace BRANCH instructions with GUARD instructions. We can do this as a preprocessing step before running the code. (In fact, we could just as easily perform this change at runtime, deciding whether to convert an instruction as we read it in.)

Accomplishments

We have implemented support for GUARD instructions in the SimpleScalar compiler. We implemented a somewhat crude technique for converting BRANCH instructions to GUARD instructions and tested the simulator on one of the provided test programs. We can adjust the technique so that it is more or less aggressive at replacing BRANCHes with GUARDs.

The results are as we expected: as we replace BRANCHes with GUARDs, the number of instructions executed by our simulator increases, but the number of branch mispredictions decreases. At present the cost of the additional instructions executed outweighs the benefit from improved branch prediction, so this actually worsens performance.

We are investigating ways to improve this. For example, right now our simulator assigns a penalty of 3 cycles for a branch misprediction. If we increase this penalty, replacing BRANCHes with GUARDs will look better.

Milestone

We successfully met our milestone: we have a working simulator.

Surprises

We have encountered no significant surprises thus far.

Revised Schedule

We still need to accomplish the following things:
Fine-tune the simulator to improve the efficiency of our GUARD instructions
Determine a realistic misprediction penalty for our simulator
Determine how aggressive we should be in converting BRANCH instructions to GUARD instructions in order to maximize performance
Test the simulator on the provided benchmarks
Write the report

We will both work on each of the tasks described above.

Resources Needed

We have a working simulator and a set of precompiled executables for that simulator. This should be all the resources we need to complete this project.