[PATCH 2/7] gdb: Add an is_declaration field to each symbol

Tom Tromey tom@tromey.com
Mon Jul 29 20:21:00 GMT 2019


>>>>> "Andrew" == Andrew Burgess <andrew.burgess@embecosm.com> writes:

Andrew> Track if a symbol is a declaration or not.  At one point we could
Andrew> possibly figure this out based on the LOC_UNRESOLVED address class of
Andrew> the symbol, but, for Fortran we mark some symbols as LOC_UNRESOLVED
Andrew> even when the DWARF supplies an address, this is because the address
Andrew> supplied by the DWARF is actually wrong.  For details look in
Andrew> dwarf2read.c and look for references to gFortran bug #40040.  I have
Andrew> confirmed that current versions of gFortran still have the issue
Andrew> mentioned in that bug report.

That bug looks like another instance of the copy relocation problem.
So, I wonder if these workarounds could be removed if/when this series
lands:

    https://sourceware.org/ml/gdb-patches/2019-06/msg00612.html

(I still haven't looked at Pedro's review in detail, but I will get to
it sooner or later.)

Tom



More information about the Gdb-patches mailing list