From: Ulf Carlsson <ulfc@calypso.engr.sgi.com>
To: dank@alumni.caltech.edu
Cc: jorge_ortiz@hp.com,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Subject: Re: Process vs. Threads
Date: 06 Mar 2001 09:32:00 -0800 [thread overview]
Message-ID: <6ovg0gq952n.fsf@calypso.engr.sgi.com> (raw)
In-Reply-To: <3AA517DB.A5963C9F@alumni.caltech.edu>
In-Reply-To: Dan Kegel's message of "Tue, 06 Mar 2001 09:01:15 -0800"
Hi,
> Can someone summarize the state of the thread changes in 2.4?
> A lot seemed to happen, but from what I gather, nothing user-visible yet.
We have the concept of thread group now. A thread group will be
created if you use the CLONE_THREAD flag from userspace. The task
structures for the threads cloned with CLONE_THREAD will be on a list
for that thread group list and the tgid field will also be copied from
the parent process. The tgid is returned to the user by getpid(), so
all the threads will seem to have the same pid from within the process
although they will show up with different pids in /proc. The tgid
implementation is IMHO braindead.
A problem seems to be that we don't check for the tgid field in
getpid(), so theoretically when you do for example raise() from a
thread the signal could be sent to a process that you didn't intend to
send a signal to.
Also if you send a signal to a process it will be delivered to the
thread with that pid and it will remain pending if that thread is
blocking the signal, which doesn't comply with pthreads. I am
currently working on a patch for this.
I have a list of other issues, but most of them can actually be solved
within glibc.
Ulf
next prev parent reply other threads:[~2001-03-06 17:33 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2001-03-06 17:01 Dan Kegel
2001-03-06 17:32 ` Ulf Carlsson [this message]
-- strict thread matches above, loose matches on Subject: below --
2001-03-08 0:17 Hank Leininger
2001-03-09 9:48 ` Albert D. Cahalan
2001-03-06 16:28 Jorge David Ortiz Fuentes
2001-03-06 16:58 ` Gregory Maxwell
2001-03-07 9:01 ` Helge Hafting
2001-03-07 23:30 ` Albert D. Cahalan
2001-03-08 3:09 ` David Schwartz
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=6ovg0gq952n.fsf@calypso.engr.sgi.com \
--to=ulfc@calypso.engr.sgi.com \
--cc=dank@alumni.caltech.edu \
--cc=jorge_ortiz@hp.com \
--cc=linux-kernel@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®