edited by
11,732 views
30 votes
30 votes

Which of the following is/are shared by all the threads in a process?

  1. Program counter
  2. Stack
  3. Address space
  4. Registers
  1. (I) and (II) only
  2. (III) only
  3. (IV) only
  4. (III) and (IV) only
edited by

5 Answers

Best answer
42 votes
42 votes

Thread is light weight process, and every thread have its own, stack, register, and PC (one of the register in CPU contain address of next instruction to be executed), so only address space that is shared by all thread for a single process.
So, option (B) is correct answer.

edited by
3 votes
3 votes
Option B is correct because every thread has it's own stack,register and program counter .hence address space is shared by thread.
2 votes
2 votes

Threads can share                

1) Code section 

2) Data Section (static and heap data)

3) Address Space

So Option B

Threads cant share Program counter, stack space and registers 

Answer:

Related questions

36 votes
36 votes
3 answers
1
Madhav asked Feb 14, 2017
12,869 views
Consider the set of process with arrival time (in milliseonds), CPU burst time (in millisecods) and priority ($0$ is the highest priority) shown below. None of the proce...
41 votes
41 votes
2 answers
2
khushtak asked Feb 14, 2017
12,944 views
In a file allocation system, which of the following allocation scheme(s) can be used if no external fragmentation is allowed?ContiguousLinkedIndexed$1$ and $3$ only$2$ on...
28 votes
28 votes
7 answers
3
Arjun asked Feb 14, 2017
13,530 views
A system shares $9$ tape drives. The current allocation and maximum requirement of tape drives for that processes are shown below:$$\begin{array}{ccc} \textbf{Process} &...
48 votes
48 votes
7 answers
4
Arjun asked Feb 14, 2017
16,785 views
Threads of a process shareglobal variables but not heapheap but not global variablesneither global variables nor heapboth heap and global variables