The Operating System and Processes: Kernel, User Space, and the PCB
Every program you've ever run was lied to about being alone. In the last course you saw the first half of the lie — virtual memory convinces each program it owns all of memory. Th…
Processes and Concurrency covers: The Operating System and Processes, Threads and Scheduling, Inter-Process Communication, Synchronization, Deadlocks and the Ruby Concurrency Model. Year 2, Quarter 6. Includes 16 exercises and 3 projects.
This course unlocks once you've finished its prerequisite. Open prerequisite →
Complete prerequisites first to enroll.
Every program you've ever run was lied to about being alone. In the last course you saw the first half of the lie — virtual memory convinces each program it owns all of memory. Th…
A process is isolated from every other process — that's its whole point. But sometimes you want concurrency inside one program: a web server handling many requests, a UI staying r…
You've used inter-process communication thousands of times, probably today. Every time you typed cat access.log | grep ERROR | wc -l, you told the shell to run three separate proc…
Here is a program that is wrong, and you might not see why: two threads each run counter = counter + 1 a million times, starting from zero. You'd expect two million. You'll get so…
The last lesson handed you locks to prevent race conditions. This lesson shows you how locks, used carelessly, create a bug that's arguably worse: deadlock — where threads freeze …
- [ ] OSTEP Ch5: Process API — Write programs using fork(), wait(), exec() in C - [ ] OSTEP Ch6: Limited Direct Execution — Measure cost of system call vs function call - [ ] OSTE…
- [ ] OSTEP Ch8: Multi-Level Feedback Queue — Simulate MLFQ with priority boost and gaming prevention - [ ] OSTEP Ch9: Proportional Share — Implement lottery scheduling simulator …
- [ ] Implement a simple shell in C — Parse commands, fork/exec, pipes (|), I/O redirect (>, <), background (&) - [ ] xv6 Lab: System calls — Add a new system call to xv6 kernel (…
- [ ] Build a process manager in C — list running processes (parse /proc), send signals, display CPU/memory usage, interactive TUI like a simple htop
Build a program that reads a config file listing commands, launches each as a child process with fork/exec, manages their lifecycle (wait, signal), and reports exit statuses. Supp…
Implement a fixed-size thread pool with a work queue. Worker threads pull tasks from a shared queue protected by mutex and condition variables. Demonstrate with a batch file proce…
- [ ] Milestone 1: REPL loop — read input, parse command + arguments, execute with fork/exec - [ ] Milestone 2: Built-in commands — cd, pwd, exit, export, history - [ ] Milestone …
- [ ] What is a process? What is the difference between a process and a thread? - [ ] Explain fork() and exec() in Unix. What does fork return to the parent vs the child? - [ ] Wh…
13 lessons. Read in order; spiral back when you need to. By the end you'll have used the core ideas twice — once on the abstract, once on something you'll meet at work next week.