re PR lto/89514 (-g -fdebug-types-section -flto gives 'Dwarf Error: bad length' in gdb)
2019-02-27 Richard Biener <rguenther@suse.de> PR debug/89514 * dwarf2out.c (size_of_die): Key on AT_ref (a)->comdat_type_p rather than on use_debug_types, doing what output_die does. (value_format): Likewise. From-SVN: r269250
This commit is contained in:
parent
a4395a846a
commit
0614006682
@ -1,3 +1,10 @@
|
||||
2019-02-27 Richard Biener <rguenther@suse.de>
|
||||
|
||||
PR debug/89514
|
||||
* dwarf2out.c (size_of_die): Key on AT_ref (a)->comdat_type_p
|
||||
rather than on use_debug_types, doing what output_die does.
|
||||
(value_format): Likewise.
|
||||
|
||||
2019-02-27 Martin Jambor <mjambor@suse.cz>
|
||||
Martin Sebor <msebor@redhat.com>
|
||||
|
||||
|
@ -9433,7 +9433,7 @@ size_of_die (dw_die_ref die)
|
||||
we use DW_FORM_ref_addr. In DWARF2, DW_FORM_ref_addr
|
||||
is sized by target address length, whereas in DWARF3
|
||||
it's always sized as an offset. */
|
||||
if (use_debug_types)
|
||||
if (AT_ref (a)->comdat_type_p)
|
||||
size += DWARF_TYPE_SIGNATURE_SIZE;
|
||||
else if (dwarf_version == 2)
|
||||
size += DWARF2_ADDR_SIZE;
|
||||
@ -9877,7 +9877,12 @@ value_format (dw_attr_node *a)
|
||||
return DW_FORM_flag;
|
||||
case dw_val_class_die_ref:
|
||||
if (AT_ref_external (a))
|
||||
return use_debug_types ? DW_FORM_ref_sig8 : DW_FORM_ref_addr;
|
||||
{
|
||||
if (AT_ref (a)->comdat_type_p)
|
||||
return DW_FORM_ref_sig8;
|
||||
else
|
||||
return DW_FORM_ref_addr;
|
||||
}
|
||||
else
|
||||
return DW_FORM_ref;
|
||||
case dw_val_class_fde_ref:
|
||||
|
Loading…
Reference in New Issue
Block a user