[lldb-dev] Infinity
Gary Benson via lldb-dev
lldb-dev at lists.llvm.org
Tue Oct 20 08:47:28 PDT 2015
Hi all,
I've been working on a platform-independent system for executables and
shared libraries to export information to debuggers and other software
development tools. It's called Infinity. The initial use case was to
allow GDB to debug multithreaded inferiors without requiring
libthread_db, but if that all works it's likely this stuff will be
added to glibc to allow debuggers to support dlmopen too, and I'm
hoping the OpenMP community will get on board too (they are currently
proposing
another libthread_db-style interface. So, I'm sending this email so
it doesn't come as a complete surprise.
The idea is basically that, rather than requiring a plugin library
that the debugger loads, in Infinity inspection functions are shipped
as DWARF bytecode in ELF notes in the actual library they are for, so,
e.g., the notes implementing what libthread_db.so currently implements
will live in libpthread.so. The idea is that the debugger keeps a
track of the notes it finds in the executables and libraries it loads,
and when complete sets arrive it enables that particular subsystem,
so, when the notes needed to support multithreaded inferiors appear
then thread debugging switches on.
I just mailed an RFC to the glibc list with notes implementing
map_lwp2thr function to get some feedback. The series starts here:
https://sourceware.org/ml/libc-alpha/2015-10/msg00690.html
This series is to build the notes, not to execute them--it's nothing
to do with debuggers--so it should be ok to look without fear of
having seen LGPL code you can't then implement. IANAL though :)
I'm currently documenting the system on the GDB wiki, starting here:
https://sourceware.org/gdb/wiki/Infinity
That won't be its final home, it's just somewhere convenient for now.
The documentation is by no means complete but I'll be filling it in
over the next few days, and most of the important concepts have at
least placeholder pages so if you subscribe to those you'll get emails
as I write.
Infinity's mailing list is infinity at sourceware.org, so please
subscribe if you're interested (by sending an empty message to
infinity-subsribe@).
Cheers,
Gary
--
http://gbenson.net/
More information about the lldb-dev
mailing list