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]
Other format: [Raw text]

Re: GDB 5.1/Core files and ptids (CONT)


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


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