Review: Threads vs. Processes
1. The process is a kernel abstraction for an independent executing program.
includes at least one “thread of control”
also includes a private address space (VAS)
- VAS requires OS kernel support
often the unit of resource ownership in kernel
- e.g., memory, open files, CPU usage
2. Threads may share an address space.
Threads have “context” just like vanilla processes.
- thread context switch vs. process context switch
Every thread must exist within some process VAS.
Processes may be “multithreaded” with thread primitives supported by a library or the kernel.