CS 241: System Programming
Offered By: University of Illinois at Urbana-Champaign via Independent
Course Description
Overview
This coursebook is being built by students and faculty from the University of Illinois. It is based on a crowd-source authoring wikibook experiment by Lawrence Angrave from CS @ Illinois, but is now its own .tex based project. Its source code is located at the Github link which you can find a pdf version of the book as well.
This book is an introduction to programming in C, and system programming (processes, threads, synchronization, networking and more!). We assume you’ve already had some programming experience, in an earlier computer science course. If you have any typos to report or content to request, feel free to file an issue at the link above. Happy Reading!
Syllabus
- Authors
- Systems Architecture
- Debugging and Environments
- Valgrind
- GDB
- Homework 0
- UIUC Specific Guidelines
- History of C
- Crash course introduction to C
- Language Facilities
- The C and Linux
- Common C Functions
- C Memory Model
- Pointers
- Common Bugs
- Logic and Program flow mistakes
- Topics
- Questions/Exercises
- Rapid Fire: Pointer Arithmetic
- File Descriptors
- Processes
- Process Contents
- Intro to Fork
- Waiting and Executing
- exec
- The fork-exec-wait Pattern
- Further Reading
- Questions/Exercises
- Introduction
- C Memory Allocation API
- Intro to Allocating
- Memory Allocator Tutorial
- Case Study: Buddy Allocator, an example of a segregated list
- Case Study: SLUB Allocator, Slab allocation
- Further Reading
- Topics
- Questions/Exercises
- Processes vs threads
- Thread Internals
- Simple Usage
- Pthread Functions
- Race Conditions
- Topics
- Questions
- Mutex
- Condition Variables
- Thread-Safe Data Structures
- Software Solutions to the Critical Section
- Working Solutions
- Implementing Counting Semaphore
- Barriers
- Ring Buffer
- Extra: Process Synchronization
- External Resources
- Topics
- Questions
- Resource Allocation Graphs
- Coffman Conditions
- Approaches to Solving Livelock and Deadlock
- Dining Philosophers
- Viable Solutions
- Topics
- Questions
- Translating Addresses
- mmap
- Pipes
- Named Pipes
- Files
- IPC Alternatives
- Topics
- Questions
- High Level Scheduler Overview
- Measurements
- Measures of Efficiency
- Scheduling Algorithms
- Topics
- Questions
- The OSI Model
- Layer 3: The Internet Protocol
- Layer 4: TCP and Client
- Layer 4: TCP Server
- Layer 4: UDP
- Layer 7: HTTP
- Non-Blocking IO
- Remote Procedure Calls
- Topics
- Questions
- What is a filesystem?
- Storing data on disk
- Permissions and bits
- Virtual filesystems and other filesystems
- Memory Mapped IO
- Reliable Single Disk Filesystems
- Simple Filesystem Model
- Topics
- Questions
- The Deep Dive of Signals
- Sending Signals
- Handling Signals
- Blocking Signals
- Signals in Child Processes and Threads
- Topics
- Questions
- Security Terminology and Ethics
- Security in C Programs
- Cyber Security
- Topics
- Review
- C
- Processes
- Memory
- Threading and Synchronization
- Deadlock
- IPC
- Filesystems
- Networking
- Security
- Signals
- The Linux Kernel
- Containerization
- Shell
- Stack Smashing
- Compiling and Linking
- Banker’s Algorithm
- Clean/Dirty Forks (Chandy/Misra Solution)
- Actor Model
- Includes and conditionals
- threads.h
- Modern Filesystems
- Linux Scheduling
- The Curious Case of Spurious Wakeups
- Condition Wait Example
- Implementing CVs with Mutexes Alone
- Higher Order Models of Synchronization
- Actor Model and Goroutines
- Scheduling Conceptually
- Networking Extra
- Assorted Man Pages
- System Programming Jokes
- Shell Shock
- Heartbleed
- Dirty Cow
- Meltdown
- Spectre
- Mars Pathfinder
- Mars Again
- Year 2038
- Northeast Blackout of 2003
- Apple IOS Unicode Handling
- Apple SSL Verification
- Sony Rootkit Installation
- Civilization and Ghandi
- The Woes of Shell Scripting
- Appnexus Double Free
- ATT Cascading Failures - 1990
Taught by
Lawrence Angrave
Tags
Related Courses
Computer Vision: The FundamentalsUniversity of California, Berkeley via Coursera Programming Languages
University of Virginia via Udacity Learn to Program: Crafting Quality Code
University of Toronto via Coursera Computational Photography
Georgia Institute of Technology via Coursera Algorithms: Design and Analysis, Part 2
Stanford University via Coursera