Question:

Which of the following component of program state is shared across threads in a multithreaded process?

Show Hint

When working with threads, remember that heap memory is shared, while stack memory is private to each thread.
Updated On: Jun 16, 2025
  • Registers
  • Auto variables
  • Heap memory
  • Stack memory
Hide Solution
collegedunia
Verified By Collegedunia

The Correct Option is C

Solution and Explanation

In a multithreaded process, threads share certain components of the program state, such as heap memory and file descriptors. However, each thread has its own stack memory and registers to maintain its execution context. Auto variables are typically stored on the stack and are thread-specific.
Was this answer helpful?
0
0