Topics studied include formal description of programming languages, lexical analysis, syntax analysis, semantic analysis, symbol tables and memory allocation and code generation. Students undertake a semester project that includes the design and implementation of a compiler for a language chosen by the instructor.
(https://www.cs.stonybrook.edu/students/Undergraduate-Studies/courses/CSE304)
Instructor: Dr. Christopher Kane
Office: New Computer Science Building, Rm. 107
Office hours: Monday/Wednesday: 2:30 - 4:30 PM, or by appoinment - on Zoom
Email: christopher.kane@stonybrook.edu
| Week | Date | Lecture Topics/Notes | Readings |
| 1 | Mon. 08/28 | Course Intro | Ch. 1 |
| Wed. 08/30 | Regular Expressions and Scanners | 2.1-2.3 | |
| Assignment 01 - Assigned: Wednesday, 08/30/2023 | |||
| Fri. 09/01 | Regular Expressions and Scanners | ||
| 2 | Mon. 09/04 | Labor Day - No Class | |
| Wed. 09/06 | Implementing Scanners | 2.4-2.7 | |
| Fri. 09/08 | Finite Automata | ||
| 3 | Mon. 09/11 | Finite Automata (cont.) | |
| Wed. 09/13 | Grammars: Parsing | 3.1-3.2 | |
| Assignment 02 - Assigned: Wednesday, 09/13/2023 | |||
| Fri. 09/15 | Top-Down Parsing | 3.3 | |
| Assignment 01 - Due: Friday, 09/15/2023 | |||
| 4 | Mon. 09/18 | Top-Down Parsing | |
| Wed. 09/20 | LR Parsers | 3.4 | |
| Fri. 09/22 | LR Parsers | ||
| 5 | Mon. 09/25 | LR Parser Family; Ambiguity, Conflicts, and Errors | 3.5-3.7 |
| Wed. 09/27 | Parser Construction | ||
| Fri. 09/29 | Parser Construction | ||
| 6 | Mon. 10/02 | Intermediate Representations | Ch. 4 |
| Wed. 10/04 | Syntax Directed Definitions, Type Systems and Type Checking | Ch. 5 | |
| Assignment 03 - Assigned: Wednesday, 10/04/2023 | |||
| Fri. 10/06 | Syntax Directed Definitions, Type Systems and Type Checking | ||
| Assignment 02 - Due: Friday, 10/06/2023 | |||
| 7 | Mon. 10/09 | Fall Break - No Class | |
| Wed. 10/11 | Midterm Exam 01 - Part 01 | ||
| Fri. 10/13 | Midterm Exam 01 - Part 02 | ||
| 8 | Mon. 10/16 | Procedure Abstraction | Ch. 6 |
| Wed. 10/18 | Procedure Abstraction | ||
| Fri. 10/20 | Runtime Storage Organization | TBD | |
| 9 | Mon. 10/23 | Runtime Storage Organization | |
| Wed. 10/25 | Intermediate Code Generation | Ch. 7 | |
| Fri. 10/27 | Intermediate Code generation (cont.) | ||
| 10 | Mon. 10/30 | Intermediate Code Generation (cont.) | |
| Wed. 11/01 | Data Flow Analysis | Ch. 9 | |
| Assignment 04 - Assigned: Wednesday, 11/01/2023 | |||
| Fri. 11/03 | Data Flow Analysis (cont.) | ||
| Assignment 03 - Due: Friday, 11/03/2023 | |||
| 11 | Mon. 11/06 | Data Flow Analysis (cont.) | |
| Wed. 11/08 | Static Single Assignment Form | 9.3 | |
| Fri. 11/10 | Static Single Assignment Form | ||
| 12 | Mon. 11/13 | Register Allocation | Ch. 13 |
| Wed. 11/15 | Register Allocation (cont.) | ||
| Assignment 05 - Assigned: Wednesday, 11/15/2023 | |||
| Fri. 11/17 | Register Allocation (cont.) | ||
| Assignment 04 - Due: Friday, 11/17/2023 | |||
| 13 | Mon. 11/20 | Catch-Up Day | |
| Wed. 11/22 | Thanksgiving Break - No Class | ||
| Fri. 11/24 | Thanksgiving Break - No Class | ||
| 14 | Mon. 11/27 | Midterm Exam 02 - Part 01 | |
| Wed. 11/29 | Midterm Exam 02 - Part 02 | ||
| Fri. 12/01 | Instruction Selection | Ch. 11 | |
| 15 | Mon. 12/04 | Instruction Selection (cont.) | |
| Wed. 12/06 | Instruction Scheduling | Ch. 12 | |
| Fri. 12/08 | Instruction Scheduling (cont.) | ||
| 16 | Mon. 12/11 | Code Optimization | 8.1-8.4 |
| Assignment 05 - Due: Monday, 12/11/2023 | |||
| Final | FINAL EXAM: Wednesday, December 13th, 2023, 5:30 PM - 8:00 PM |