CS 671 - Compilers
 Course Links:
Instructor
Syllabus
Lectures
Assignments
 Useful Tools:
LexAndYacc
Phoenix
Pin
Prof. Kim Hazelwood
Computer Science Department
University of Virginia

Course Time: Tue/Thu 11:00-12:15 PM
Course Location: MEC 215

Office: Olsson 209
Office Hours: Mon 2PM-3PM
              (or by appointment)

This course covers the theory and practice of compiler design and implementation. We will cover both the front end (language-dependent) and back-end (machine-dependent) components of modern compilers. We will discuss the impact of language and architectural decisions on compiler design, as well as many of the challenges that remain at the forefront of code generation and optimization research.

Throughout the semester, you will complete 5-6 assignments that consist of written questions and/or implementation tasks. By the end of the semester, you will be familiar with automatic front-end generation tools (flex and bison), a modern compilation infrastructure (Phoenix), and a program analysis tool (Pin). In addition, you will understand the theoretical backing of each phase in a modern compiler.

Course Announcements.

  • Here is our syllabus
  • Feel free to provide anonymous feedback at any time
  • Project Presentations: Monday, May 5 @ 9 AM
  • Final Project Report: Friday, May 9 @ 9 PM

Course Topics.

Below is a rough course outline.

  • Structure of Compilers
  • The Front End
    • Lexical Analysis (Scanning)
    • Syntactic Analysis (Parsing)
    • Abstract Syntax Trees
    • Semantic Analysis
    • Scoping, Type Checking, Symbol Tables
    • Activation Records
    • Intermediate Code
  • The Back End
    • Instruction Selection
    • Data-Flow Analysis
    • Control-Flow Analysis
    • Register Allocation
    • Loop Optimizations
    • Instruction Scheduling
    • Interprocedural Analysis and Inlining
  • Advanced Topics
    • Size and Power Optimizations
    • Just-In-Time Compilation
    • Adaptive Optimizations
    • Binary Translation

Required Text.

Compilers: Principles, Techniques, and Tools (2nd Edition)
by Alfred Aho, Monica Lam, Ravi Sethi, and Jeffrey Ullman

When you get your book, be sure to apply the corrections listed on the book's website.