[RFC][PATCH] Allow JIT unwinder provide symbol information

Doug Evans dje@google.com
Wed Feb 12 07:50:00 GMT 2014


On Tue, Feb 11, 2014 at 2:25 PM, Doug Evans <dje@google.com> wrote:
> On Tue, Jan 14, 2014 at 4:39 PM, Alexander Smundak <asmundak@google.com> wrote:
>> I fixed the patch based on your comments, except for the one
>> about using LWP for thread identification.
>> Waiting for the opinions about the approach used in this RFC patch.
>>
>>>  > +/* Returns LWP ID of the current thread or 0.  */
>>>  > +
>>>  > +typedef long (gdb_get_lwp) (void);

Another issue that occurs to me is what if the loaded jit shared
library on some platform (not necessarily linux) wants to use
ptid.tid, even if both ptid.lwp and ptid.tid are available?

Does it make sense to provide routines that access each?

Pedro, the issue is what handle on a thread to export to the
jit-reader-load shared library.
Java for linux wants the lwp, and currently the patch will return
ptid.tid instead of ptid.lwp if  lwp == 0 to shield the shared lib
from gdb vs gdbserver thread ptid usage differences, on the assumption
that if lwp == 0 then tid is actually lwp.

On a separate note,
IIRC we still have to decide how to handle version 1 jit-reader-load
shared libs.



More information about the Gdb-patches mailing list