> 2012-11-27 Sterling Augustine <saugust...@google.com> > > Backport changes to fission implementation required by > trunk. See > http://gcc.gnu.org/ml/gcc-patches/2012-10/msg02684.html and > susbsequent messages for a full description of what needed to > change for it to be accepted into trunk. Most of the original > changes were already in google-4_7, so this is just the diff > between the two implementations. > > These changes to make the resulting debug info smaller, so are useful > to have on this branch. > > * dwarf2out.h (addr_table_entry_struct): Forward declare. > (dw_val_struct): Change name and associated type of field val_index > to val_entry. > * dwarf2out.c (NOT_INDEXED, NO_INDEX_ASSIGNED, UNRELOCATED_OFFSET, > RELOCATED_OFFSET): New defines. > (ate_kind): New enum with enumerators ate_kind_rtx, > ate_kind_rtx_dtprel, ate_kind_label. > (addr_table_entry_struct, addr_table_entry): New structure and type. > (dw_loc_list_struct): Change field name from begin_index to > begin_entry, likewise with the type. > (new_loc_descr, build_cfa_loc, new_addr_loc_descr, add_AT_flag, > add_AT_int, add_AT_unsigned, add_AT_double, add_AT_vec, > add_AT_string, add_AT_die_ref, add_AT_fde_ref, > add_AT_loc, add_AT_loc_list, add_AT_addr, add_AT_file, > add_AT_vms_delta, > add_AT_lbl_id, add_AT_lineptr, add_AT_macptr, add_AT_offset): > Change field name from val_index to val_entry, and intialize properly. > (size_of_loc_descr, output_loc_operands): Add assertion and update > call. > (set_AT_index): Remove obsolete function. > (remove_addr_table_entry, add_AT_lbl_id, > add_AT_range_list, add_ranges_by_labels): Update prototypes, adjust > all calls in file. > (dtprel_bool): New enum with dtprel_false and dtprel_true. > (dw_addr_op, new_addr_loc_descr): Update functions to use dtprel_bool, > plus additional logic to handle val_entries. Use RELOCATED_OFFSET > and UNRELOCATED_OFFSET. > (AT_index, output_loc_list): Update comment. Update logic to handle > val_entry. > (add_AT_low_high_pc): Update comment. Change field name from > val_index to val_entry, and call add_addr_table entry. > (indirect_string_node, index_string_table): Delete obsolete types, > variables and tables. > (AT_string_form): Move most logic to ... > (find_string_form): ... here and ... > (set_indirect_string): ... here. New function. > (addr_index_table): Change type from vector to hash table. > (addr_table_entry_do_hash, addr_table_entry_eq, init_addr_table_entry, > index_addr_table_entry): New functions. > (add_addr_table_entry): Update prototype. Convert logic to > hash tables. > (remove_loc_list_addr_table_entries): Convert logic to hash tables. > (size_of_die, value_format, output_attr_index_or_value): Use > NOT_INDEXED and NO_INDEX_ASSIGNED. > (output_range_list_offset): Use RELOCATED_OFFSET. Update comment. > (output_comdat_type_unit): Check OBJECT_FORMAT_ELF. > (add_ranges_by_labels, loc_descriptor, mem_loc_descriptor, > loc_list_from_tree, add_const_value_attribute): Update comment. Use > dtprel_bool enumerators. > (output_macinfo_op): Fix FIXME by handling DW_FORM_strp's and > DW_FORM_GNU_str_index. > (save_macinfo_strings, index_string, output_index_string_offset, > output_index_string, output_indirect_strings, > output_addr_table_entry): > New functions. > (output_indirect_string): Check refcount. > (output_addr_table): Update logic for hash tables. > (resolve_addr_in_expr, resolve_addr, hash_loc_operands, > compare_loc_operands, index_location_lists): Update logic for > val_entry. > (dwarf2out_finish): Update logic for val_entry. Call > htab_traverse_noresize multiple times, save macinfo_strings, > index_string output_addr_table, output_indirect_strings. Add comments. > Remove calls to output_addr_table, output_index_strings, > and index_location_lists.
This is OK for the google/gcc-4_7 branch. Thanks! -cary