This is the mail archive of the gdb-patches@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]

macro-expanding expressions in GDB



Daniel Berlin <dan@cgsoftware.com> writes:
> Speaking of real parsers, i've hooked up GCC's cpplib to GDB's c
> expression parser if anyone is interested in the work.  I'll
> eventually submit it once the hooks to do the necessary gdb lookups to
> handle macros are done.  Neil said he'd try to have something

This is a feature to die for.  Fantastic.

I have two concerns about using cpplib:
- I don't want GDB builds to require the GCC sources around.  This is
  mostly bureacracy --- we'd need to have cpplib moved into its own
  top-level directory, so we could share it with GCC.
- I wonder how much of cpplib we actually need.  We don't need
  #includes, #ifs, or CPP expression evaluation.  cpplib seems
  heavyweight.  This is somewhat nitpicky.

Sorry, which Niel?  If I can find the bandwidth, I'd love to do the
symbol table support for this.

> I also submitted patches to gcc to make it produce the dwarf2 macro
> info necessary for us to let the user use macros from GDB that are
> used in the source.

And we don't even need to wait for that.  We can add the macro info to
the .s files manually, and test against those files.


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