CS226/326 : Compilers (Spring 2001)

Instructor

Name: David Beazley
Office : Ryerson 257B
Phone : (773) 702-9111
email : beazley@cs.uchicago.edu
Office hours: Whenever I am around (which is most of the time)

Teaching Assistants

Overview

This course covers concepts central to the theory, design, and implementation of modern compilers. Topics include but are not limited to lexical analysis, parsing, syntax directed translation, intermediate code generation, and optimization. Over the course of the quarter, you will develop a real compiler that compiles a simple language into SPARC assembly code.

Prerequisites

Compilers is an intense course that involves topics from nearly every area of computer science--especially topics related to theory, algorithms, programming languages, and architecture. Although this is an applied course, material from the following courses will probably be the most useful: In addition, some knowledge of the following courses certainly won't hurt although it isn't really required:

The bottom line is that this course involves a mix of programming and theory. If you are not comfortable with the idea of having to write a large software project or having to do a little mathematics, this is the wrong course for you.

Textbooks

I will be attempting to cover the first 10 chapters of this book.

Grading Structure

Grading Scale

Graduate Credit

Graduate students and undergraduates taking the course for graduate credit will be required to perform additional work on the projects, homework, and exams. These additional requirements will be clearly indicated as "graduate only."

Class Accounts

You will need to get a CS account for this class in order to get access to department machines. By the end of the course, your compiler will be expected to work on a set of Sun workstations. However, for the first 6-7 weeks, you will be able to do all of your work on almost any machine.

Programming Languages

The preferred programming language for this class is Python. Python is a high-level interpreted object oriented programming language that has about every feature you could ever possibly want to use. Plus, it is freely available for just about every kind of machine imaginable. Unlike operating systems, the point of this class is not to spend all of your time messing around with C/C++ pointers, bit twiddling, and segmentation faults. I think you will like Python.

If you are looking for an extra challenge, we will also accept programs that have been written in Standard ML. Please see me if you are considering this option.

The use of C or C++ for this class is highly discouraged.

The Compiler Project

A substantial part of your grade in this course is determined by a substantial programming project in which you will implement a compiler. This project is broken up into 4-5 precisely defined stages where each stage builds upon the previous stage. You will not receive a passing grade for the course unless you also receive a passing grade on the project. Unlike the project in operating systems, the stages of the compiler project are a little more managable and self contained. However, don't be fooled--the compiler project is difficult and will still require a reasonable amount of effort on your part.

Homework

Throughout the quarter, you will be asked to complete a variety of daily/weekly homework assignments. These assignments may involve a small amount of programming as well as the solution to problems in the book. Those of you who know me probably know that I am not generally known for giving lots of daily homework. However, compilers is a conceptually challenging class that is a little difficult to grasp by only working on the project. The purpose of these assignments is to help illustrate concepts and to make it easier to get a handle on the project.

Academic Dishonesty

You are encouraged to interact with your classmates and to discuss various design aspects of the projects and assignments. However, the work you hand in must be your own. Blatant copying or sharing of solutions or source code will result in an F in the course and referral to the college administration.

Where to go for help

Compilers is one of the most challenging computer science courses. Do not hesistate to see me or the TAs if you have any problems or concerns.