This document covers the comprehensive guide for the Operating Systems: Three Easy Pieces (OSTEP) course within the OSSU Computer Science curriculum. It details two distinct learning approaches, technical setup requirements, project implementation workflows, and resource management for this systems programming course.
For general Core Systems curriculum information, see Core Systems. For community support resources, see Getting Help.
The OSTEP course offers two distinct learning paths with different time commitments and technical depth requirements.
The Base approach provides fundamental operating systems education through textbook study and homework completion, requiring approximately 80 hours of work over 8 weeks coursepages/ostep/README.md8-17
Core Requirements:
ostep-homework repository coursepages/ostep/README.md15Course Resources:
pages.cs.wisc.edu/~remzi/OSTEP/ coursepages/ostep/README.md23ostep-homework repository coursepages/ostep/README.md25github.com/xxyzz/ostep-hw coursepages/ostep/README.md26Sources: coursepages/ostep/README.md8-26
The Extended approach involves intensive systems programming with C and x86 assembly, requiring over 200 hours and targeting students specializing in systems programming coursepages/ostep/README.md10
Additional Requirements:
Sources: coursepages/ostep/README.md10-53
The following diagram illustrates the relationship between course materials and the recommended project sequence.
Sources: coursepages/ostep/README.md41-70 coursepages/ostep/Reading-order.md1-14
To implement xv6 projects, specific environmental configurations are necessary.
Sources: coursepages/ostep/Project-1B-initial-xv6.md7-16 coursepages/ostep/README.md19-25
The Extended approach follows a structured progression through system call implementation, process management, memory virtualization, and file systems.
Adding a new system call (e.g., getreadcount() or settickets()) requires modifications across several files to bridge user-space requests to kernel-space execution coursepages/ostep/Project-1B-initial-xv6.md20-30
| File | Purpose | Modifications |
|---|---|---|
syscall.h | System call number definitions | Add SYS_syscallname macros coursepages/ostep/Scheduling-xv6-lottery.md38-40 |
syscall.c | System call dispatch table | Add function pointer entries to the syscall array coursepages/ostep/Scheduling-xv6-lottery.md36-40 |
sysproc.c | System call wrapper implementations | Add sys_syscallname() to extract arguments via argint or argptr coursepages/ostep/Scheduling-xv6-lottery.md42-46 |
usys.S | Assembly system call stubs | Add SYSCALL(syscallname) macros coursepages/ostep/Scheduling-xv6-lottery.md50-52 |
user.h | User-space function declarations | Add function prototypes for user code coursepages/ostep/Scheduling-xv6-lottery.md54-58 |
defs.h | Kernel function declarations | Add kernel function prototypes to access code across the kernel coursepages/ostep/Scheduling-xv6-lottery.md18 |
Sources: coursepages/ostep/Project-1B-initial-xv6.md20-30 coursepages/ostep/Scheduling-xv6-lottery.md15-60
The scheduling-xv6-lottery project demonstrates how to modify the core process structure and scheduler logic.
Sources: coursepages/ostep/Scheduling-xv6-lottery.md64-88
The processes-shell project (Project 2A) involves creating a Unix shell from scratch, focusing on process creation and memory safety coursepages/ostep/Project-2A-processes-shell.md1-10
Key Implementation Details:
exit, cd, and path directly in the shell coursepages/ostep/Project-2A-processes-shell.md6-8execv for external commands and fork for process creation coursepages/ostep/Project-2A-processes-shell.md16strtok (not thread-safe); use strsep while preserving original pointers for free() to avoid page table corruption coursepages/ostep/Project-2A-processes-shell.md37-39Sources: coursepages/ostep/Project-2A-processes-shell.md1-46
The vm-xv6-intro project focuses on virtual memory system implementation.
Key Implementation Details:
start.zip distribution coursepages/ostep/vm-xv6-intro.md7-11null.c to demonstrate the lack of memory safety in the initial xv6 environment coursepages/ostep/vm-xv6-intro.md11objdump -d user/null.o to compare program results with actual machine code coursepages/ostep/vm-xv6-intro.md11Sources: coursepages/ostep/vm-xv6-intro.md1-14
The Extended approach requires significant C experience. If you are new to C, expect to spend 8-10 hours per week for 3-5 weeks on prerequisites coursepages/ostep/README.md51
Recommended Resources:
initial-reverse project: A litmus test for C readiness coursepages/ostep/README.md37Sources: coursepages/ostep/README.md32-51
Primary Documentation:
Sources: coursepages/ostep/Project-1B-initial-xv6.md24-26 coursepages/ostep/Project-2A-processes-shell.md14 coursepages/ostep/Scheduling-xv6-lottery.md5
Refresh this wiki