CS4410/6410: Compilers

Fall 2026

Contact information

Office Email Office hours
Olin Shivers WVH 318 shivers@ccs Wed Wed 1:30–2:30 & by appt

Lectures

Tuesday 3:25–5:05 Robinson 109
Friday 3:25–5:05 Robinson 109

Other

Course schedule (lectures, projects, exams)
(This is the central file for course-related information.)

Piazza: https://piazza.com/northeastern/fall2026/cs44106410

Slides for intro-to-SML lecture.


Assignments

  1. Lexer (due Mon 9/21 midnight pm)
  2. Parser (due Thu 10/8 midnight pm)
  3. Static semantics (due Mon 10/19 midnight pm)
  4. Frame analysis (due Mon 11/9 midnight pm)
  5. Translation to IR (due Mon 11/9 midnight pm)
  6. Instruction selection (due Mon 11/16 midnight)
  7. Live-variable Data-flow analyser (due Mon 11/23 midnight pm)
  8. Register allocation (due Mon 12/7 midnight pm)
  9. Integration (due Mon 12/14 midnight pm)

Academic integrity policy

…that is to say: what is the course policy on what is permitted, and what is considered cheating?

First, you may use AI coding assistants. But it's not recommended. You won't understand your code if you don't write it yourself. This is not a job; it's an educational task.

Second, you are permitted — in fact, you are strongly encouraged — to discuss issues related to the Tiger compiler project with other students in the class. In particular, you should use the course piazza page to discuss the class projects. You can even talk about ways to handle specific problems that have to be handled in the implementation of the compiler's various passes.

But you can't look at someone else's code (besides your partner's). You can't show your code to anyone besides your partner. You have to keep your discussion and descriptions limited to English and mathematics. That is the boundary — because you have to write your own code. If you go outside this boundary: you are cheating.

Even if we don't catch you: you are still cheating.

Resources

Books

MIPS and SPIM

SPIM is a simulator written by James Larus for the MIPS-II ISA, a real-world processor architecture that is a very clean RISC design.

ML

Improved Canonicaliser

Appel provides a module of code for the Tiger-compiler project called the "canonicaliser," which lowers a program in the IR language to a form closer to machine code. This code is hard to read, as the invariants of the lowered/canonicalised form are not expressed in the type of the result form. Well, and the code isn't commented, either.

I rewrote this code using a target data type that makes the new form explicit in the type structure. It is much clearer and type-driven (as well as voluminously commented). It also has a slightly better commutativity analysis.

The code comes in two forms. The first version is exactly as described above. Then I took that, and converted the improved code to use the original IR data type for the target, producing a version that is a drop-in replacement for Appel's code.

So, read the first version but use the second.