[Bug debug/88878] .debug_pubnames/types empty with -flto

jan.kratochvil at redhat dot com gcc-bugzilla@gcc.gnu.org
Wed Jul 29 13:20:45 GMT 2020


--- Comment #9 from Jan Kratochvil <jan.kratochvil at redhat dot com> ---
(In reply to Richard Biener from comment #8)
> The .debug_types section isn't supposed to be output when in_lto_p
> (that's for the LTRANS units where we generally do not output any
> types into DWARF).  Instead .debug_types has to be output during
> dwarf2out_early_finish when we write the declaration dwarf units,
> the "early" debug info.  That should now be done.

Thanks for the explanation, I see -fdebug-types-section -flto does work with
trunk without any patch, great!

> You can verify with a small testcase and -gpubnames [-flto] where
> with -flto both .debug_pubtype and .debug_pubnames are missing.

I do not think anyone is interested in those, for DWARF-5 they are officially
 * Replace the .debug_pubnames and .debug_pubtypes sections with a single and
   more functional name index section, .debug_names .

And for DWARF-4 those were replaced by GNU .gdb_index .

More information about the Gcc-bugs mailing list