Hi! add_AT_wide is the only add_AT_* that doesn't clear or otherwise initialize dw_attr_val.val_entry field, so it contains random garbage, which isn't desirable when ggc walks it during collections.
Supposedly this omission originates from the val_entry addition being added everywhere only after wide-int branch grabbed some add_AT_* routine from dwarf2out.c as example for the add_AT_wide addition. Bootstrapped/regtested on x86_64-linux and i686-linux, committed to trunk and 5.1 as obvious. 2015-04-20 Jakub Jelinek <ja...@redhat.com> PR debug/65807 * dwarf2out.c (add_AT_wide): Clear attr.dw_attr_val.val_entry. --- gcc/dwarf2out.c.jj 2015-04-17 09:45:08.000000000 +0200 +++ gcc/dwarf2out.c 2015-04-20 11:37:59.544596284 +0200 @@ -3886,6 +3886,7 @@ add_AT_wide (dw_die_ref die, enum dwarf_ attr.dw_attr = attr_kind; attr.dw_attr_val.val_class = dw_val_class_wide_int; + attr.dw_attr_val.val_entry = NULL; attr.dw_attr_val.v.val_wide = ggc_alloc<wide_int> (); *attr.dw_attr_val.v.val_wide = w; add_dwarf_attr (die, &attr); Jakub