Processes, Threads & the Kernel

The one program standing between every other program and the real machine, handing out turns on the chip and private-looking slices of memory so a handful of real cores can serve hundreds of programs at once.
Before you start. The last lesson, How Code Becomes Execution (compilers, stack & heap), left one program’s instructions running as a single stream on the CPU, fetched and carried out one at a time, as if that program owned the chip outright. This lesson is about the hundreds of programs actually doing that on the same handful of cores at once, and the one piece of software that keeps them from reading or overwriting each other.