diff options
author | Jakub Jelinek <jakub@redhat.com> | 2021-03-31 09:11:29 +0200 |
---|---|---|
committer | Jakub Jelinek <jakub@redhat.com> | 2021-03-31 09:11:29 +0200 |
commit | a49a96f681bf13c6e77644d4507e867f00f93fe6 (patch) | |
tree | 8eeb88c4ba5e60b07582f1d6fc90a237664b0ec0 /gcc/tree-data-ref.c | |
parent | 0989e99470c2a6797bacf6d04888bc9a46a632a8 (diff) | |
download | gcc-a49a96f681bf13c6e77644d4507e867f00f93fe6.zip gcc-a49a96f681bf13c6e77644d4507e867f00f93fe6.tar.gz gcc-a49a96f681bf13c6e77644d4507e867f00f93fe6.tar.bz2 |
i386, debug: Default to -gdwarf-4 on Windows targets with broken ld.bfd [PR98860]
As mentioned in the PR, before the
https://sourceware.org/git/?p=binutils-gdb.git;a=commit;h=ba6eb62ff0ea9843a018cfd7cd06777bd66ae0a0
fix from March 1st, PECOFF ld.bfd didn't know about .debug_loclists,
.debug_rnglists and other debug sections new in DWARF 5. Unfortunately,
unlike for ELF linkers, that means the sections were placed in wrong
ordering with wrong VMA/LMA, so the resulting executables are apparently
unusable.
As that is pretty new change, newer than 2.35.2 or 2.36 binutils releases,
the following patch adds a workaround that turns -gdwarf-4 by default
instead of -gdwarf-5 if a broken linker is found at configure time.
Users can still explicitly play with -gdwarf-5 and either use a non-broken
linker or use custom linker scripts for the broken one, but at least
by default it should work.
2021-03-31 Jakub Jelinek <jakub@redhat.com>
PR bootstrap/98860
* configure.ac (HAVE_LD_BROKEN_PE_DWARF5): New AC_DEFINE if PECOFF
linker doesn't support DWARF sections new in DWARF5.
* config/i386/i386-options.c (ix86_option_override_internal): Default
to dwarf_version 4 if HAVE_LD_BROKEN_PE_DWARF5 for TARGET_PECOFF
targets.
* config.in: Regenerated.
* configure: Regenerated.
Diffstat (limited to 'gcc/tree-data-ref.c')
0 files changed, 0 insertions, 0 deletions