This is the mail archive of the
gdb@sources.redhat.com
mailing list for the GDB project.
Re: GDB 5.1/Core files and ptids (CONT)
- From: Kevin Buettner <kevinb at redhat dot com>
- To: Michael Snyder <msnyder at redhat dot com>, Takis Psarogiannakopoulos <takis at XFree86 dot Org>
- Cc: kevinb at redhat dot com, gdb at sources dot redhat dot com, binutils at sources dot redhat dot com
- Date: Fri, 18 Jan 2002 11:23:45 -0700
- Subject: Re: GDB 5.1/Core files and ptids (CONT)
- References: <Pine.BSF.4.21.0201180744300.654-100000@public.xfree86.org> <3C485748.776A@redhat.com>
On Jan 18, 9:11am, Michael Snyder wrote:
> Takis Psarogiannakopoulos wrote:
> > Unfortunately it seems that the change of mixed pids to ptids
> > has more problems that I thought in the start of this thread.
> > I am not sure after that change how any OS's that uses corelow.c
> > can debug a multi threaded core file!
>
> In fact, I think Takis is right. I noticed while doing the
> gcore work that the thread IDs from multi-threaded corefiles
> on Solaris seemed to be broken, perhaps because corelow
> has not been made ptid-aware.
Yep, I agree. As I pointed out to Takis in an earlier message, I think
the right way to fix it is to modify both corelow.c on the GDB side
and elf.c on the bfd side.
My suggestion was that instead of naming sections .reg/PIDLWP where
PIDLWP is a combined (numeric) pid and lwp identifier that these
sections instead be named .reg/PID+LWP where PID is the pid and LWP is
the lwp.
When the LWP doesn't exist or is simply zero, we simply use .reg/PID
as before. (Or we could use .reg/PID+0. It doesn't really matter
so long as both sides are in agreement.)
Kevin