This is the mail archive of the mailing list for the GCC 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: [PATCH 5/5] add libcc1

On 29/10/14 10:53, Paolo Bonzini wrote:
> On 10/29/2014 11:51 AM, Jakub Jelinek wrote:
>> On Wed, Oct 29, 2014 at 11:37:42AM +0100, Paolo Bonzini wrote:
>>> On 10/29/2014 11:28 AM, Jakub Jelinek wrote:
>>>> If this passes bootstrap/regtest, is it ok for trunk (should fix
>>>> two bootstrap issues)?  Is the
>>>> patch ok too (that one already tested; another bootstrap issue)?
>>> Both seem okay, though I'd have to look at the whole thread to
>>> understand what libcc1 is. :)
>> It is a library for communication between the debugger and
>> a GCC plugin (and the plugin itself).  So, the library is
>> dlopened into GDB and the plugin that links against that library
>> is dlopened by GCC when GDB asks the library it dlopened to
>> run the compiler with the plugin.

Adding on to what Jakub said, it allows GDB access to GCC's parser.
There are a number of reasons why, but right now that means we can
compile code snippets in GDB (without the source of the current
inferior), allow access to symbols of that inferior in that source
snippet, etc.  We then inject and execute it.

We are currently writing a wiki article about it.  Not required reading
or anything, but more information for the curious.

(That is a work in progress).  There is also a video of a presentation
I did at Cauldron somewhere.



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