Mirror of the gdb mailing list
 help / color / mirror / Atom feed
From: "J. Johnston" <jjohnstn@redhat.com>
To: Daniel Jacobowitz <drow@mvista.com>
Cc: gdb@sources.redhat.com
Subject: Re: gcore and nptl threads on linux
Date: Wed, 05 Mar 2003 17:05:00 -0000	[thread overview]
Message-ID: <3E662E68.7010205@redhat.com> (raw)
In-Reply-To: <20030305005218.GA9222@nevyn.them.org>



Daniel Jacobowitz wrote:
> On Tue, Mar 04, 2003 at 06:40:51PM -0500, J. Johnston wrote:
> 
>>There is a problem with implementing gcore on linux with nptl thread
>>support.  Under the linux nptl model, each thread is mapped to an
>>lwpid which is distinct from the pid of the process that created the
>>thread.
>>
>>The current linux gcore code is merging the pid with the tid into an 
>>unsigned
>>long value.  This works ok in the old model because the tid and pids are 
>>only
>>16-bits in length.  This no longer can work because tids in the nptl model 
>>are actually
>>addresses and are not restricted to 16-bits.
> 
> 
> I think this used to cause problems, too - it really should be just the
> lwpid, I'd think.  For these cases at least.
> 
> 
>>This change would allow linux-proc.c to get the lwp where possible in a 
>>cleaner
>>fashion.
>>
>>If nobody has any major objections to this proposal, I can post a patch 
>>shortly.
> 
> 
> What do you plan to do when there is not a mapping, i.e. in an M:N
> environment?  This interface assumes 1:1.
> 

I would think the null_ptid would serve in such a case.

-- Jeff J.




  reply	other threads:[~2003-03-05 17:05 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-03-04 23:40 J. Johnston
2003-03-05  0:52 ` Daniel Jacobowitz
2003-03-05 17:05   ` J. Johnston [this message]
2003-03-05 17:25     ` Daniel Jacobowitz
2003-03-06  0:56       ` Andrew Cagney
2003-03-06  1:04         ` Daniel Jacobowitz
2003-03-06  1:44           ` Andrew Cagney
2003-03-06  1:49             ` Daniel Jacobowitz
2003-03-06  1:27         ` J. Johnston
2003-03-06 20:17           ` Andrew Cagney
2003-03-06 20:21             ` Daniel Jacobowitz
2003-03-11  0:00               ` J. Johnston
2003-03-11 14:30                 ` Andrew Cagney
2003-04-15 21:43                   ` Andrew Cagney

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=3E662E68.7010205@redhat.com \
    --to=jjohnstn@redhat.com \
    --cc=drow@mvista.com \
    --cc=gdb@sources.redhat.com \
    /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