In this section, we'll learn about the what and why of multithreading on the Linux platform. We will begin by answering the FAQ, "what exactly is a thread?".
Multithreading concepts
What exactly is a thread?
In the good (or bad?) old days, Unix programmers had a straightforward software model (which got inherited pretty much exactly by other OSes and vendors): there is a process that lives in a virtual address space (VAS); the VAS essentially consists of homogeneous regions (essentially collections of virtual pages) called segments: text, data, other mappings (libraries), and stack. The text is really the executable—in fact, the machine—code that is fed to the processor. We have certainly covered...