This is the mail archive of the gdb@sources.redhat.com mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: How do you use GDB to debug GDB


On Mon, Mar 19, 2001 at 05:44:12PM -0500, Frank Ch. Eigler wrote:
>Fernando Nasser <fnasser@cygnus.com> writes:
>: [...]
>: Start your "top" gdb in a separate shell.  Use the command attach passing the Windows 
>: PID (as opposed to the Unix PID) of the other GDB.
>: [...]
>
>By the way, why does cygwin gdb use Windows PIDs only instead of
>cygwin PIDs, or some fall-back defaulting from one to the other?

GDB uses Windows pids because it can debug more than just cygwin
applications.  In older DLLs it was possible to have the same number
indicate both a Windows PID and a Cygwin PID, so there was ambiguity.
You don't want to have a mechanism which disallows the ability to
debug a program or ends up debugging the wrong program.

In current net releases of Cygwin it is (or should be) impossible
to have the cygwin pid == the windows pid except for when they
are the same process.

So, I guess you could have a fallback mechanism if somebody wanted
to implement it.

cgf


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]