This is the mail archive of the
gdb-patches@sources.redhat.com
mailing list for the GDB project.
Re: thread ptids when debugging from core file (x86-linux)
- From: "Nathan J. Williams" <nathanw at wasabisystems dot com>
- To: Joel Brobecker <brobecker at gnat dot com>
- Cc: gdb-patches at sources dot redhat dot com
- Date: 06 Aug 2004 00:40:06 -0400
- Subject: Re: thread ptids when debugging from core file (x86-linux)
- Organization: Wasabi Systems, Inc.
- References: <20040806040959.GL1192@gnat.com>
Joel Brobecker <brobecker@gnat.com> writes:
> According to corelow.c:add_to_thread_list(), the thread PTID
> is a degenerated {pid, 0, 0} where pid is just the number in the section
> name where the thread has been dumped (ie section ".reg/1234" => thread
> ptid = {1234, 0, 0}).
I've always assumed that corelow.c's mapping between .reg sections and
threads was intended as a minimal fallback. The module I wrote for
NetBSD's threads (which I'll get into shape for the FSF tree Real Soon
Now) punts that list and generates its own list of threads from the
memory structures of libpthread in the core file, just as it would for
a live process.
- Nathan