Class Tuesday / Thursday 2:00-3:20pm in Wean 8427
Fall 2026
12 units
Jonathan Aldrich
aldrich at cs dot cmu dot edu
TCS 422
Office hour: TBA
For appointments outside of office hours, email the instructor.
Course Description
Rust is transforming systems programming, giving developers the tools to write memory- and time-efficient code at a systems level of abstraction while providing safety guarantees stronger than most high-level languages. This course will provide comprehensive coverage of safe systems programming techniques, using Rust as the vehicle of instruction although the techniques covered can be applied in other languages (typically with fewer static guarantees). We will cover ownership types, safe manual memory management, safe concurrency, asynchronous code, and how to provide a safe interface that encapsulates unsafe code. Students will practice these techniques while writing systems programs from a variety of domains, including threaded interpreters, webassembly executables in the browser, embedded device controllers, and distributed consistency protocols. We will also cover Rust specifics, including ownership, borrowing, lifetimes, Rust's concurrency model, async, error handling, unsafe, the foreign function interface, traits, functional programming, reference counted pointers, modules and crates, and macros.
Prerequisites.
15-213/15-513 or equivalent knowledge and skills.
Course Syllabus and Policies
The
syllabus covers course learning objectives, textbooks, assessments, late work, and other policies.
Schedule
| Date |
Topic and Slides |
Additional Reading or Code |
Assignments Due |
| Aug 25 |
Introduction: Safe Systems Programming in Rust |
simple-interpreter.zip |
|
| Aug 27 |
Writing Interpreters |
|
|
| Sep 1 |
Advanced Interpreter Implementation |
|
HW1 (warm-up): An Interpreter in Rust (hw1.zip) |
| Sep 3 |
Just-In-Time Compilers |
|
|
| Sep 8 |
Practical Language Implementation |
|
|
| Sep 10 |
(no class) |
|
|
| Sep 15 |
Traits and Raytracing |
|
HW2: Faster Language Implementations |
| Sep 17 |
Safe Concurrency |
|
|
| Sep 22 |
Unafe Concurrency |
|
|
| Sep 24 |
Asynchrony in Rust |
09-demos.zip |
|
| Sep 29 |
Eventual Consistency and CRDTs |
10-demos.zip |
HW3: Raytracing |
| Oct 1 |
Collaborative Text, Anti-Entropy, and Testing Convergence |
11-demos.zip |
|
| Oct 6 |
Miri, Tree Borrows, and BorrowSanitizer |
|
|
| Oct 8 |
Abstracting Hardware in Rust |
12-demos.zip |
|
| Oct 20 |
More Hardware Abstraction: Drivers, HAL, and DMA |
13-demos.zip |
due Oct 21: HW4: Replicated Store |
| Oct 22 |
Interrupts and Concurrency on Bare Metal |
14-demos.zip |
|
| Oct 27 |
Verification in Rust: Specs, Proofs, and the Solver |
15-demos.zip |
|
| Oct 29 |
Views and Invariants in Verus |
16-demos.zip |
|
| Nov 3 |
No class - Democracy Day |
|
HW5: Temperature Safety Monitor |
| Nov 5 |
Proving a State Machine Safe |
17-demos.zip |
|
| Nov 10 |
Verifying unsafe code |
18-demos.zip |
|
| Nov 12 |
Functional Programming in Rust |
19-demos.zip |
|
| Nov 17 |
Modules, Visibility, and Macros |
20-demos.zip |
HW6: Verification in Rust |
| Nov 19 |
FFI and Lifetimes in Depth |
21-demos.zip |
Project Proposal |
| Nov 24 |
Project Discussions (optional, online) |
|
|
| Nov 26 |
No class - Thanksgiving |
|
|
| Dec 1 |
Raft |
|
|
| Dec 3 |
The Future of Systems Languages: Meerkat and Mojo |
|
|
| Dec 7 |
Final project presentations |
|
Project Presentation Slides and Code |