This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
[0/7] fork-child client targets, always a thread
- From: Pedro Alves <pedro at codesourcery dot com>
- To: gdb-patches at sourceware dot org
- Date: Fri, 8 Aug 2008 02:32:41 +0100
- Subject: [0/7] fork-child client targets, always a thread
Hi,
This series adjusts targets that use fork-child.c/fork_inferior to
always register the main thread in GDB's thread table.
The whole series was tested on x86_64-unknown-linux-gnu, i386-pc-solaris2.11
(OpenSolaris 10), i386-unknown-openbsd4.3, i386-unknown-freebsd6.0,
i386-unknown-freebsd7.0 and i686-unknown-gnu0.3 (Debian GNU/Hurd).
I'm also changing inf-ttrace.c, but unfortunatelly I have no access
to HP-UX to be able to test it.
I can't tell if I need to do much regarding the aix-thread target,
as I don't have AIX access. A tweak to aix-thread.c:sync_threadlists
may be required to detect the case of the main thread getting
a pthread identifier, and calling thread_change_ptid instead of
add_thread. aix-thread.c:pd_update(1) could also use thread_change_ptid
when setting inferior_ptid. I'd propose a patch, but I'm fairly certain
I'd only be breaking stuff. :-(
--
Pedro Alves