diff options
author | Jan Kratochvil <jan.kratochvil@redhat.com> | 2012-03-16 18:26:02 +0000 |
---|---|---|
committer | Jan Kratochvil <jan.kratochvil@redhat.com> | 2012-03-16 18:26:02 +0000 |
commit | ab260dad3930dcea79a76a1d62b2210be782c68d (patch) | |
tree | 94d6710f60390bd4f8b4aa194386e5ea54b92a98 /gdb/dwarf2read.c | |
parent | c366c1f032f28dd7747ecc148dcec7419f42ab94 (diff) | |
download | gdb-ab260dad3930dcea79a76a1d62b2210be782c68d.zip gdb-ab260dad3930dcea79a76a1d62b2210be782c68d.tar.gz gdb-ab260dad3930dcea79a76a1d62b2210be782c68d.tar.bz2 |
gdb/
PR symtab/13777
* dwarf2read.c (process_full_comp_unit): Set LOCATIONS_VALID only for
GCC >=4.5.
gdb/testsuite/
PR symtab/13777
* gdb.dwarf2/dw2-skip-prologue.S (DW_AT_producer): Set it to 4.5.0.
Diffstat (limited to 'gdb/dwarf2read.c')
-rw-r--r-- | gdb/dwarf2read.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c index 7944e0f..2eb5f40 100644 --- a/gdb/dwarf2read.c +++ b/gdb/dwarf2read.c @@ -4868,7 +4868,9 @@ process_full_comp_unit (struct dwarf2_per_cu_data *per_cu) /* GCC-4.0 has started to support -fvar-tracking. GCC-3.x still can produce DW_AT_location with location lists but it can be possibly - invalid without -fvar-tracking. + invalid without -fvar-tracking. Still up to GCC-4.4.x incl. 4.4.0 + there were bugs in prologue debug info, fixed later in GCC-4.5 + by "unwind info for epilogues" patch (which is not directly related). For -gdwarf-4 type units LOCATIONS_VALID indication is fortunately not needed, it would be wrong due to missing DW_AT_producer there. @@ -4876,7 +4878,7 @@ process_full_comp_unit (struct dwarf2_per_cu_data *per_cu) Still one can confuse GDB by using non-standard GCC compilation options - this waits on GCC PR other/32998 (-frecord-gcc-switches). */ - if (cu->has_loclist && gcc_4_minor >= 0) + if (cu->has_loclist && gcc_4_minor >= 5) symtab->locations_valid = 1; if (gcc_4_minor >= 5) |