CS 162: Operating Systems
CS162 Notes #
Here are my notes for the Fall 2021 offering of CS162, Berkeley’s OS course, based on Anderson and Dahlin’s textbook “Operating Systems: Principles and Practice”.
Table of Contents #
- OS Basics
Chapter 1: OS Basics
What is an operating system? An operating system has three main roles: Referee: The OS manages protection, isolation, and allocation of...
- Processes
Chapter 2: Processes
The Process Abstraction A process is an execution environment with restricted rights. A process consists of: An address space Thread(s) of control running...
- Threads
Chapter 3: Threads
The Thread Abstraction A thread is a single unique context, or unit of concurrency, for execution that fully describes the program...
- IO
Chapter 4: I/O
UNIX Abstraction: Everything is a File A file is a named collection of data in a file system. In the POSIX...
- Synchronization
Chapter 5: Synchronization
Race Conditions and Locks If two independent threads need to modify and read the same values, there could be multiple outputs...
- Scheduling
Chapter 6: Scheduling
Introduction When multiple tasks need to be done on a single CPU, we need to figure out a way to distribute...
- Address Translation
Chapter 7: Address Translation
Introduction Every modern computer has physical memory inside of it, that might look something like this: Physical RAM modules typically contain anywhere...
- Caching
Chapter 8: Caching
Introduction At this point, we've solved nearly all of the problems with base and bound memory translation. But there is one...
- File Systems
Chapter 9: File Systems
I/O Drivers A computer handles I/O on its end using several mechanisms: The bus, a common set of communication wires, carries data transfer...
- GDB Reference
GDB Reference
Run with args: r Breakpoint: b Conditional breakpoint: b if or condition on existing Step into: step...
How to contribute #
See the
contributing guide
Thanks for your interest in contributing to my notes! There's a lot of room for improvement, and I don't have...Contributing
You might notice that some sections are empty (specifically, buffer management policies in
Caching
Introduction
At this point, we've solved nearly all of the problems with base and bound memory translation. But there is one...
Race Conditions and Locks
If two independent threads need to modify and read the same values, there could be multiple outputs...Chapter 8: Caching
Chapter 5: Synchronization