CS 5363: Compiler Project, Extra Credit #2

Submission Deadline: 8:30pm, December 1, 2005

Second Extra Credit Assignment

Extra credit can be earned by replacing the dummy register allocator described in the instructions for part #4 with a proper graph-coloring register allocator. This register allocation should analyze live ranges of virtual registers in the final MIPS code (c.f., 13.5.1), build an interference graph (c.f., 13.5.3), spill and color the live ranges according to a bottom-up Chaitin-Briggs graph coloring algorithm (c.f., 13.5.5). In order to avoid repeated coloring after spilling, you may reserve a couple registers for temporaries involved in the spill code. To receive the maximum amount of extra credit points, you must implement some kind of register coalescing (c.f., 13.5.6).

Deliverables and Submission

You may include these optimizations in your final submission for part #4. Please, include the following additional information in the cover letter for that assignment:

  1. the fact that you implemented a register allocator
  2. specify what spill metric you used and why you chose it
  3. whether the register allocator supports coalescing of live ranges
  4. any other enhancements you added to the base algorithm

Also make sure that your included test cases demonstrate and test your optimizations including the spilling of live ranges for which there are insufficient registers.

Grading Criteria

You may earn extra credit worth up to 10% of the total class grade by implementing a proper register allocator. To earn all 10 points, your register allocator should include support for coalescing live ranges.

As a matter of policy, late work will not be accepted.

Errata

There may need to be corrections, clarifications, or other modifications to these instructions, you are responsible for monitoring the class web site, monitoring your CS account mailboxes, and listening during lecture for announcements related to this assignment.