Example 1 · level 1
Two threads belonging to the same process in a Linux-based system will share which of the following?
- Address space and open files
- Stack and program counter
- Register set and local variables
- Each thread has its own heap
Show solution
- Identify that threads are lightweight units of a process.
- Recall that shared resources include code, data, and OS resources.
- Recall that private resources include stack and registers.
Answer: Address space and open files