17-350/17-650 Safe Systems Programming in Rust

Class Tuesday / Thursday 2:00-3:20pm
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
Aug 27 Writing Interpreters
Sep 1 Advanced Interpreter Implementation
Sep 3 Just-In-Time Compilers Warm-up: An Interpreter in Rust
Sep 8 Error Handling
Sep 10 Encapsulating Unsafe Code
Sep 15 Traits
Sep 17 WebAssembly and Foreign Function Interfaces Faster Language Implementations
Sep 22 Safe Concurrency
Sep 24 Modules, Packages, and Crates
Sep 29 Asynchrony
Oct 1 The Raft Protocol WASM Image Processing
Oct 6 Miri, Tree Borrows, and BorrowSanitizer
Oct 8 Research talk TBA
Oct 20 Hardware Abstraction and the Typestate Pattern
Oct 22 Embedded Systems Programming Distributed Key-Value Store
Oct 27 Functional Programming
Oct 29 Verification in Rust (1)
Nov 3 No class - Democracy Day
Nov 5 Verification in Rust (2) Embedded Safety Monitor
Nov 10 Verification in Rust (3)
Nov 12 Verification in Rust (4)
Nov 17 Macros
Nov 19 Research Talk TBA Verification in Rust
Nov 24 Project Discussions Project Proposal
Nov 26 No class - Thanksgiving
Dec 1 Project Discussions
Dec 3 Future of Systems Languages
Finals week Final project presentations Project Presentation Slides and Code