Thread address space...
- From: "Mozis" <chokshi.jaydeep@xxxxxxxxx>
- Date: 31 Dec 2005 05:20:44 -0800
The sentense "Threads share parent process address space."
in pthrad_create(..), we pass address of function wich acts as body of
thread. Now I dont understand how come a thread shares process address
space. It can just share the global variables which comes under the
data segment. so I think a thread can share following of process,
1. Code segment: NO
2. Data Segment: Only the global variables.
Now, as we pass a function as a body of a thread, it must have a code
segment (correct me If I'm wrong), a stack segment, and data segment
(intitalized variables in functions). then how come we say it's sharing
address space of parent process, just because its sharing its global
variables!!
Regards,
Mozis.
.
- Prev by Date: Re: How does rpm command compare 2 rpm files' version?
- Previous by thread: Use of alternate stack for signal handler
- Index(es):
Relevant Pages
|