GCC Middle and Back End API Reference
|
Data Structures | |
struct | indirect_string_node |
struct | dwarf_file_data |
struct | deferred_locations_struct |
struct | addr_table_entry_struct |
union | addr_table_entry_struct::addr_table_entry_struct_union |
struct | dw_loc_list_struct |
struct | dw_line_info_struct |
struct | dw_line_info_table_struct |
struct | dw_attr_struct |
struct | die_struct |
union | die_struct::die_symbol_or_type_node |
struct | pubname_struct |
struct | dw_ranges_struct |
struct | macinfo_struct |
struct | dw_ranges_by_label_struct |
struct | comdat_type_struct |
struct | limbo_die_struct |
struct | skeleton_chain_struct |
struct | die_arg_entry_struct |
struct | var_loc_node |
struct | var_loc_list_def |
struct | call_arg_loc_node |
struct | cached_dw_loc_list_def |
struct | checksum_attributes |
struct | cu_hash_table_entry |
struct | cu_hash_table_entry_hasher |
struct | decl_table_entry |
struct | decl_table_entry_hasher |
struct | external_ref |
struct | external_ref_hasher |
struct | file_info |
struct | dir_info |
struct | file_name_acquire_data |
struct | macinfo_entry_hasher |
struct | comdat_type_hasher |
struct | loc_list_hasher |
Enumerations | |
enum | ate_kind { ate_kind_rtx, ate_kind_rtx_dtprel, ate_kind_label } |
enum | dw_line_info_opcode { LI_set_address, LI_set_line, LI_set_file, LI_set_column, LI_negate_stmt, LI_set_prologue_end, LI_set_epilogue_begin, LI_set_discriminator } |
enum | dtprel_bool { dtprel_false = 0, dtprel_true = 1 } |
typedef struct addr_table_entry_struct addr_table_entry |
typedef struct cached_dw_loc_list_def cached_dw_loc_list |
typedef struct comdat_type_struct comdat_type_node |
The comdat type node structure.
typedef struct comdat_type_struct* comdat_type_node_ref |
typedef const char* dchar_p |
typedef struct deferred_locations_struct deferred_locations |
typedef struct die_arg_entry_struct die_arg_entry |
typedef struct die_struct die_node |
The Debugging Information Entry (DIE) structure. DIEs form a tree. The children of each node form a circular list linked by die_sib. die_child points to the node *before* the "first" child node.
typedef struct dw_attr_struct dw_attr_node |
Each DIE attribute has a field specifying the attribute kind, a link to the next attribute in the chain, and an attribute value. Attributes are typically linked below the DIE they modify.
typedef struct dw_attr_struct* dw_attr_ref |
Define typedefs here to avoid circular dependencies.
typedef struct dw_line_info_struct dw_line_info_entry |
typedef struct dw_line_info_struct* dw_line_info_ref |
typedef struct dw_line_info_table_struct dw_line_info_table |
typedef dw_line_info_table* dw_line_info_table_p |
typedef struct dw_loc_list_struct dw_loc_list_node |
Location lists are ranges + location descriptions for that range, so you can track variables that are in different places over their entire life.
typedef long int dw_offset |
Various DIE's use offsets relative to the beginning of the .debug_info section to refer to each other.
typedef struct dw_ranges_by_label_struct* dw_ranges_by_label_ref |
typedef struct dw_ranges_struct* dw_ranges_ref |
typedef struct limbo_die_struct limbo_die_node |
The limbo die list structure.
typedef hash_table<loc_list_hasher> loc_list_hash_type |
typedef struct macinfo_struct macinfo_entry |
A structure to hold a macinfo entry.
typedef struct pubname_struct pubname_entry |
The pubname structure
typedef struct pubname_struct* pubname_ref |
typedef struct skeleton_chain_struct skeleton_chain_node |
typedef struct var_loc_list_def var_loc_list |
enum ate_kind |
enum dtprel_bool |
enum dw_line_info_opcode |
The entries in the line_info table more-or-less mirror the opcodes that are used in the real dwarf line table. Arrays of these entries are collected per section when DWARF2_ASM_LINE_DEBUG_INFO is not supported.
|
static |
|
inlinestatic |
Add an 'abstract_origin' attribute below a given DIE. The DIE is found by looking in either the type declaration or object declaration equate table.
References add_AT_die_ref(), decl_function_context(), dwarf2out_abstract_function(), lookup_decl_die(), and lookup_type_die().
|
static |
Add DW_AT_accessibility attribute to DIE if needed.
References add_AT_unsigned(), die_struct::die_parent, and die_struct::die_tag.
Referenced by gen_enumeration_type_die(), gen_field_die(), gen_struct_or_union_type_die(), gen_subprogram_die(), gen_typedef_die(), and gen_variable_die().
|
static |
Referenced by add_AT_addr(), add_AT_lbl_id(), add_AT_low_high_pc(), index_location_lists(), and new_addr_loc_descr().
|
static |
Add attr to the address table entry to the table. Defer setting an index until output time.
References addr_index_table, addr_table_entry_do_hash(), addr_table_entry_eq(), init_addr_table_entry(), and addr_table_entry_struct::refcount.
|
inlinestatic |
Add an address constant attribute value to a DIE. When using dwarf_split_debug_info, address attributes in dies destined for the final executable should be direct references--setting the parameter force_direct ensures this behavior.
References add_addr_table_entry(), add_dwarf_attr(), ate_kind_rtx, dw_attr_struct::dw_attr, dw_attr_struct::dw_attr_val, dw_val_class_addr, dw_val_struct::v, dw_val_struct::dw_val_struct_union::val_addr, dw_val_struct::val_class, and dw_val_struct::val_entry.
Referenced by add_name_and_src_coords_attributes(), dwarf2out_finish(), and gen_call_site_die().
|
static |
Referenced by dwarf2out_finish(), and generate_type_signature().
|
inlinestatic |
Add an 8-byte data attribute value to a DIE.
References add_dwarf_attr(), dw_attr_struct::dw_attr, dw_attr_struct::dw_attr_val, dw_val_class_data8, memcpy(), dw_val_struct::v, dw_val_struct::val_class, dw_val_struct::dw_val_struct_union::val_data8, and dw_val_struct::val_entry.
|
static |
Referenced by add_abstract_origin_attribute(), add_AT_specification(), add_bound_info(), add_byte_size_attribute(), add_gnat_descriptive_type_attribute(), add_pure_or_virtual_attribute(), add_sibling_attributes(), add_type_attribute(), clone_as_declaration(), dwarf2_build_local_stub(), dwarf2out_imported_module_or_decl_1(), gen_call_site_die(), gen_formal_types_die(), gen_namespace_die(), gen_ptr_to_mbr_type_die(), gen_struct_or_union_type_die(), gen_subprogram_die(), and modified_type_die().
|
inlinestatic |
Add a DIE reference attribute value to a DIE.
References add_dwarf_attr(), dw_val_struct::dw_val_struct_union::dw_val_die_union::die, dw_attr_struct::dw_attr, dw_attr_struct::dw_attr_val, dw_val_class_die_ref, dw_val_struct::dw_val_struct_union::dw_val_die_union::external, dw_val_struct::v, dw_val_struct::val_class, dw_val_struct::dw_val_struct_union::val_die_ref, and dw_val_struct::val_entry.
|
inlinestatic |
Add an unsigned double integer attribute value to a DIE.
References add_dwarf_attr(), dw_attr_struct::dw_attr, dw_attr_struct::dw_attr_val, dw_val_class_const_double, double_int::high, double_int::low, dw_val_struct::v, dw_val_struct::val_class, dw_val_struct::dw_val_struct_union::val_double, and dw_val_struct::val_entry.
Referenced by add_bound_info(), add_const_value_attribute(), and gen_enumeration_type_die().
|
static |
|
inlinestatic |
Add an FDE reference attribute value to a DIE.
References add_dwarf_attr(), dw_attr_struct::dw_attr, dw_attr_struct::dw_attr_val, dw_val_class_fde_ref, dw_val_struct::v, dw_val_struct::val_class, dw_val_struct::val_entry, and dw_val_struct::dw_val_struct_union::val_fde_index.
|
inlinestatic |
Add a file attribute value to a DIE.
References add_dwarf_attr(), dw_attr_struct::dw_attr, dw_attr_struct::dw_attr_val, dw_val_class_file, dw_val_struct::v, dw_val_struct::val_class, dw_val_struct::val_entry, and dw_val_struct::dw_val_struct_union::val_file.
Referenced by add_call_src_coords_attributes(), add_src_coords_attributes(), dwarf2out_imported_module_or_decl_1(), gen_subprogram_die(), and gen_variable_die().
|
static |
Referenced by add_AT_pubnames(), add_bound_info(), add_calling_convention_attribute(), add_prototyped_attribute(), clone_as_declaration(), gen_array_type_die(), gen_call_site_die(), gen_const_die(), gen_enumeration_type_die(), gen_field_die(), gen_formal_parameter_die(), gen_formal_types_die(), gen_generic_params_dies(), gen_namespace_die(), gen_struct_or_union_type_die(), gen_subprogram_die(), gen_variable_die(), and modified_type_die().
|
inlinestatic |
Add a flag value attribute to a DIE.
References add_dwarf_attr(), dw_attr_struct::dw_attr, dw_attr_struct::dw_attr_val, dw_val_class_flag, dw_val_struct::v, dw_val_struct::val_class, dw_val_struct::val_entry, and dw_val_struct::dw_val_struct_union::val_flag.
|
static |
|
inlinestatic |
Add a signed integer attribute value to a DIE.
References add_dwarf_attr(), dw_attr_struct::dw_attr, dw_attr_struct::dw_attr_val, dw_val_class_const, dw_val_struct::v, dw_val_struct::val_class, dw_val_struct::val_entry, and dw_val_struct::dw_val_struct_union::val_int.
|
inlinestatic |
Add a label identifier attribute value to a DIE.
References add_addr_table_entry(), add_dwarf_attr(), ate_kind_label, dw_attr_struct::dw_attr, dw_attr_struct::dw_attr_val, dw_val_class_lbl_id, dw_val_struct::v, dw_val_struct::val_class, dw_val_struct::val_entry, and dw_val_struct::dw_val_struct_union::val_lbl_id.
Referenced by add_high_low_attributes(), dwarf2out_vms_debug_main_pointer(), gen_call_site_die(), gen_entry_point_die(), and gen_label_die().
|
inlinestatic |
Add a section offset attribute value to a DIE, an offset into the debug_line section.
References add_dwarf_attr(), dw_attr_struct::dw_attr, dw_attr_struct::dw_attr_val, dw_val_class_lineptr, dw_val_struct::v, dw_val_struct::val_class, dw_val_struct::val_entry, and dw_val_struct::dw_val_struct_union::val_lbl_id.
Referenced by add_top_level_skeleton_die_attrs(), and dwarf2out_finish().
|
static |
|
inlinestatic |
Add a location description attribute value to a DIE.
References add_dwarf_attr(), dw_attr_struct::dw_attr, dw_attr_struct::dw_attr_val, dw_val_class_loc, dw_val_struct::v, dw_val_struct::val_class, dw_val_struct::val_entry, and dw_val_struct::dw_val_struct_union::val_loc.
|
static |
Referenced by add_AT_location_description(), and gen_subprogram_die().
|
inlinestatic |
|
inlinestatic |
The following routines define various Dwarf attributes and any data associated with them.
Add a location description attribute value to a DIE. This emits location attributes suitable for whole variables and whole parameters. Note that the location attributes for struct fields are generated by the routine `data_member_location_attribute' below.
References add_AT_loc(), add_AT_loc_list(), dw_loc_list_struct::expr, and single_element_loc_list_p().
Referenced by add_bound_info(), add_location_or_const_value_attribute(), gen_array_type_die(), gen_subprogram_die(), and gen_variable_die().
|
inlinestatic |
Add DW_AT_low_pc and DW_AT_high_pc to a DIE. When using dwarf_split_debug_info, address attributes in dies destined for the final executable have force_direct set to avoid using indexed references.
References add_addr_table_entry(), add_dwarf_attr(), ate_kind_label, dw_attr_struct::dw_attr, dw_attr_struct::dw_attr_val, dw_val_class_high_pc, dw_val_class_lbl_id, dw_val_struct::v, dw_val_struct::val_class, dw_val_struct::val_entry, and dw_val_struct::dw_val_struct_union::val_lbl_id.
Referenced by add_high_low_attributes(), dwarf2out_finish(), and gen_subprogram_die().
|
inlinestatic |
Add a section offset attribute value to a DIE, an offset into the debug_macinfo section.
References add_dwarf_attr(), dw_attr_struct::dw_attr, dw_attr_struct::dw_attr_val, dw_val_class_macptr, dw_val_struct::v, dw_val_struct::val_class, dw_val_struct::val_entry, and dw_val_struct::dw_val_struct_union::val_lbl_id.
Referenced by dwarf2out_finish().
|
inlinestatic |
Add an offset attribute value to a DIE.
References add_dwarf_attr(), dw_attr_struct::dw_attr, dw_attr_struct::dw_attr_val, dw_val_class_offset, offset, dw_val_struct::v, dw_val_struct::val_class, dw_val_struct::val_entry, and dw_val_struct::dw_val_struct_union::val_offset.
|
static |
Add the DW_AT_GNU_pubnames and DW_AT_GNU_pubtypes attributes.
References add_AT_flag(), and want_pubnames().
Referenced by add_top_level_skeleton_die_attrs(), and dwarf2out_finish().
|
static |
Referenced by add_high_low_attributes(), and add_ranges_by_labels().
|
static |
|
static |
Referenced by copy_declaration_context(), gen_struct_or_union_type_die(), gen_subprogram_die(), and gen_variable_die().
|
inlinestatic |
Add an AT_specification attribute to a DIE, and also make the back pointer from the specification to the definition.
References add_AT_die_ref(), and die_struct::die_definition.
|
static |
|
inlinestatic |
Add a string attribute value to a DIE.
References add_dwarf_attr(), dw_attr_struct::dw_attr, dw_attr_struct::dw_attr_val, dw_val_class_str, find_AT_string(), dw_val_struct::v, dw_val_struct::val_class, dw_val_struct::val_entry, and dw_val_struct::dw_val_struct_union::val_str.
|
inlinestatic |
Add an unsigned integer attribute value to a DIE.
References add_dwarf_attr(), dw_attr_struct::dw_attr, dw_attr_struct::dw_attr_val, dw_val_class_unsigned_const, dw_val_struct::v, dw_val_struct::val_class, dw_val_struct::val_entry, and dw_val_struct::dw_val_struct_union::val_unsigned.
Referenced by add_accessibility_attribute(), add_bit_offset_attribute(), add_bit_size_attribute(), add_bound_info(), add_byte_size_attribute(), add_call_src_coords_attributes(), add_calling_convention_attribute(), add_const_value_attribute(), add_data_member_location_attribute(), add_descr_info_field(), add_pure_or_virtual_attribute(), add_src_coords_attributes(), base_type_die(), break_out_comdat_types(), dwarf2out_imported_module_or_decl_1(), gen_array_type_die(), gen_compile_unit_die(), gen_descr_array_type_die(), gen_inheritance_die(), gen_pointer_type_die(), gen_reference_type_die(), gen_subprogram_die(), gen_variable_die(), modified_type_die(), and subrange_type_die().
|
inlinestatic |
Add a floating point attribute value to a DIE and return it.
References add_dwarf_attr(), dw_vec_struct::array, dw_attr_struct::dw_attr, dw_attr_struct::dw_attr_val, dw_val_class_vec, dw_vec_struct::elt_size, dw_vec_struct::length, dw_val_struct::v, dw_val_struct::val_class, dw_val_struct::val_entry, and dw_val_struct::dw_val_struct_union::val_vec.
Referenced by add_const_value_attribute(), and tree_add_const_value_attribute().
|
inlinestatic |
Add a vms delta attribute value to a DIE.
References add_dwarf_attr(), dw_attr_struct::dw_attr, dw_attr_struct::dw_attr_val, dw_val_class_vms_delta, dw_val_struct::dw_val_struct_union::dw_val_vms_delta_union::lbl1, dw_val_struct::dw_val_struct_union::dw_val_vms_delta_union::lbl2, dw_val_struct::v, dw_val_struct::val_class, dw_val_struct::val_entry, and dw_val_struct::dw_val_struct_union::val_vms_delta.
Referenced by gen_subprogram_die().
|
static |
Referenced by gen_field_die().
|
inlinestatic |
For a FIELD_DECL node which represents a bit-field, output an attribute which specifies the distance in bits from the highest order bit of the "containing object" for the bit-field to the highest order bit of the bit-field itself. For any given bit-field, the "containing object" is a hypothetical object (of some integral or enum type) within which the given bit-field lives. The type of this hypothetical "containing object" is always the same as the declared type of the individual bit-field itself. The determination of the exact location of the "containing object" for a bit-field is rather complicated. It's handled by the `field_byte_offset' function (above). Note that it is the size (in bytes) of the hypothetical "containing object" which will be given in the DW_AT_byte_size attribute for this bit-field. (See `byte_size_attribute' above).
References add_AT_int(), add_AT_unsigned(), bit_position(), field_byte_offset(), host_integerp(), int_bit_position(), simple_type_size_in_bits(), and tree_low_cst().
|
static |
Referenced by gen_field_die().
|
inlinestatic |
For a FIELD_DECL node which represents a bit field, output an attribute which specifies the length in bits of the given field.
References add_AT_unsigned(), host_integerp(), and tree_low_cst().
|
static |
Referenced by add_bound_info(), add_subscript_info(), gen_array_type_die(), and subrange_type_die().
|
static |
Given a tree node describing an array bound (either lower or upper) output a representation for that bound.
References add_AT_die_ref(), add_AT_double(), add_AT_flag(), add_AT_loc(), add_AT_location_description(), add_AT_unsigned(), add_bound_info(), add_type_attribute(), comp_unit_die(), current_function_decl, dw_loc_list_struct::expr, HOST_BITS_PER_WIDE_INT, host_integerp(), HOST_WIDE_INT, loc_list_from_tree(), lookup_decl_die(), lower_bound_default(), new_die(), simple_type_size_in_bits(), single_element_loc_list_p(), and tree_low_cst().
|
static |
Referenced by gen_enumeration_type_die(), gen_field_die(), and gen_struct_or_union_type_die().
|
static |
|
inlinestatic |
A helper function for gen_inlined_subroutine_die. Add source coordinate attributes to the DIE for a block STMT, to describe where the inlined function was called from. This is similar to add_src_coords_attributes.
References add_AT_file(), add_AT_unsigned(), expand_location(), and lookup_filename().
Referenced by gen_inlined_subroutine_die().
|
static |
Referenced by gen_subprogram_die().
|
static |
Given an object die, add the calling convention attribute for the function call type.
References add_AT_flag(), add_AT_unsigned(), is_fortran(), and targetm.
|
static |
Referenced by break_out_comdat_types(), break_out_includes(), clone_tree(), clone_tree_hash(), copy_ancestor_tree(), copy_declaration_context(), copy_decls_walk(), dwarf2out_finish(), gen_enumeration_type_die(), gen_struct_or_union_type_die(), gen_subprogram_die(), generate_skeleton_ancestor_tree(), generate_skeleton_bottom_up(), new_die(), process_scope_var(), remove_child_or_replace_with_skeleton(), and splice_child_die().
|
static |
Add a CHILD_DIE as the last child of DIE.
References die_struct::die_child, die_struct::die_parent, and die_struct::die_sib.
|
static |
Referenced by dwarf2out_finish(), and gen_compile_unit_die().
|
static |
Generate a DW_AT_comp_dir attribute for DIE.
References add_AT_string(), and comp_dir_string().
|
static |
|
static |
Attach a DW_AT_const_value attribute for a variable or a parameter which does not have a "location" either in memory or in a register. These things can arise in GNU C when a constant is passed as an actual parameter to an inlined function. They can also arise in C++ where declared constants do not necessarily get memory "homes".
References add_AT_double(), add_AT_int(), add_AT_loc(), add_AT_string(), add_AT_unsigned(), add_AT_vec(), add_const_value_attribute(), add_loc_descr(), const_ok_for_output(), dtprel_false, insert_double(), insert_float(), insert_int(), new_addr_loc_descr(), new_loc_descr(), resolve_one_addr(), rtx_to_double_int(), double_int::to_shwi(), and vec_safe_push().
|
static |
Referenced by gen_field_die(), and gen_inheritance_die().
|
static |
Attach the specialized form of location attribute used for data members of struct and union types. In the special case of a FIELD_DECL node which represents a bit-field, the "offset" part of this special location descriptor must indicate the distance in bytes from the lowest-addressed byte of the containing struct or union type to the lowest-addressed byte of the "containing object" for the bit-field. (See the `field_byte_offset' function above). For any given bit-field, the "containing object" is a hypothetical object (of some integral or enum type) within which the given bit-field lives. The type of this hypothetical "containing object" is always the same as the declared type of the individual bit-field itself (for GCC anyway... the DWARF spec doesn't actually mandate this). Note that it is the size (in bytes) of the hypothetical "containing object" which will be given in the DW_AT_byte_size attribute for this bit-field. (See the `byte_size_attribute' function below.) It is also used when calculating the value of the DW_AT_bit_offset attribute. (See the `bit_offset_attribute' function below.)
References add_AT_int(), add_AT_loc(), add_AT_unsigned(), add_loc_descr(), field_byte_offset(), int_loc_descriptor(), is_cxx(), new_loc_descr(), offset, and tree_low_cst().
|
static |
References add_AT_loc(), add_AT_unsigned(), descr_info_loc(), host_integerp(), and tree_low_cst().
Referenced by gen_descr_array_type_die().
|
static |
Referenced by add_AT_addr(), add_AT_data8(), add_AT_die_ref(), add_AT_double(), add_AT_fde_ref(), add_AT_file(), add_AT_flag(), add_AT_int(), add_AT_lbl_id(), add_AT_lineptr(), add_AT_loc(), add_AT_loc_list(), add_AT_low_high_pc(), add_AT_macptr(), add_AT_offset(), add_AT_range_list(), add_AT_string(), add_AT_unsigned(), add_AT_vec(), add_AT_vms_delta(), add_skeleton_AT_string(), clone_as_declaration(), clone_die(), and copy_declaration_context().
|
inlinestatic |
Add an attribute/value pair to a DIE.
References die_struct::die_attr, vec_safe_push(), and vec_safe_reserve().
|
static |
Referenced by add_pubtype().
|
static |
Add an enumerator to the pubnames section.
References pubname_struct::die, get_AT_string(), pubname_struct::name, and vec_safe_push().
|
static |
Retrieve the descriptive type of TYPE, if any, make sure it has a DIE and attach a DW_AT_GNAT_descriptive_type attribute to the DIE of TYPE accordingly. ??? This is a temporary measure until after we're able to generate regular DWARF for the complex Ada type system.
References add_AT_die_ref(), lang_hooks_for_types::descriptive_type, gen_type_die(), lookup_type_die(), and lang_hooks::types.
Referenced by gen_array_type_die(), gen_enumeration_type_die(), gen_struct_or_union_type_die(), and modified_type_die().
|
inlinestatic |
A helper function for gen_lexical_block_die and gen_inlined_subroutine_die. Add low_pc and high_pc attributes to the DIE for a block STMT.
References add_AT_lbl_id(), add_AT_low_high_pc(), add_AT_range_list(), add_ranges(), die_struct::die_parent, dw_attr_struct::dw_attr_val, dw_val_class_range_list, get_AT(), inlined_function_outer_scope_p(), dw_ranges_struct::num, dw_val_struct::v, dw_val_struct::val_class, and dw_val_struct::dw_val_struct_union::val_offset.
Referenced by gen_inlined_subroutine_die(), and gen_lexical_block_die().
|
static |
Add a DW_AT_linkage_name or DW_AT_MIPS_linkage_name attribute for the given decl. This used to be a vendor extension until after DWARF 4 standardized it.
References add_AT_string().
Referenced by add_linkage_name(), dwarf2out_finish(), and gen_typedef_die().
|
static |
Add DW_AT_{,MIPS_}linkage_name attribute for the given decl.
References add_linkage_attr(), limbo_die_struct::created_for, deferred_asm_name, limbo_die_struct::die, die_struct::die_tag, and limbo_die_struct::next.
Referenced by add_name_and_src_coords_attributes(), gen_subprogram_die(), and gen_variable_die().
|
inlinestatic |
Add a location description term to a location description expression.
References dw_loc_descr_struct::dw_loc_next.
Referenced by add_const_value_attribute(), add_data_member_location_attribute(), add_loc_descr_to_each(), address_of_int_loc_descriptor(), based_loc_descr(), bswap_loc_descriptor(), build_cfa_aligned_loc(), build_cfa_loc(), clz_loc_descriptor(), compare_loc_descriptor(), concat_loc_descriptor(), concatn_loc_descriptor(), convert_descriptor_to_mode(), descr_info_loc(), dw_loc_list_1(), int_loc_descriptor(), int_shift_loc_descriptor(), loc_descr_plus_const(), loc_descriptor(), loc_list_from_tree(), mem_loc_descriptor(), minmax_loc_descriptor(), multiple_reg_loc_descriptor(), one_reg_loc_descriptor(), popcount_loc_descriptor(), reg_loc_descriptor(), resolve_addr_in_expr(), rotate_loc_descriptor(), scompare_loc_descriptor(), typed_binop(), and ucompare_loc_descriptor().
|
static |
Referenced by concat_loc_descriptor(), concatn_loc_descriptor(), loc_descriptor(), and multiple_reg_loc_descriptor().
|
static |
Optionally add a DW_OP_piece term to a location description expression. DW_OP_piece is only added if the location description expression already doesn't end with DW_OP_piece.
References dw_loc_descr_struct::dw_loc_next, and new_loc_descr().
|
static |
To each location in list LIST add loc descr REF.
References add_loc_descr(), copy(), dw_loc_descr_struct::dw_loc_next, dw_loc_list_struct::dw_loc_next, dw_loc_list_struct::expr, and memcpy().
Referenced by add_loc_list(), loc_list_for_address_of_addr_expr_of_indirect_ref(), and loc_list_from_tree().
|
static |
Given two lists RET and LIST produce location list that is result of adding expression in LIST to expression in RET on each position in program. Might be destructive on both RET and LIST. TODO: We handle only simple cases of RET or LIST having at most one element. General case would inolve sorting the lists in program order and merging them that will need some additional work. Adding that will improve quality of debug info especially for SRA-ed structures.
References add_loc_descr_to_each(), dw_loc_list_struct::dw_loc_next, expansion_failed(), and dw_loc_list_struct::expr.
Referenced by loc_list_for_address_of_addr_expr_of_indirect_ref(), and loc_list_from_tree().
|
static |
Generate *either* a DW_AT_location attribute or else a DW_AT_const_value data attribute for a variable or a parameter. We generate the DW_AT_const_value attribute only in those cases where the given variable or parameter does not have a true "location" either in memory or in a register. This can happen (for example) when a constant is passed as an actual argument in a call to an inline function. (It's possible that these things can crop up in other ways also.) Note that one type of constant value which can be passed into an inlined function is a constant pointer. This can happen for example if an actual argument in an inlined function call evaluates to a compile-time constant address. CACHE_P is true if it is worth caching the location list for DECL, so that future calls can reuse it rather than regenerate it from scratch. This is true for BLOCK_NONLOCALIZED_VARS in inlined subroutines, since we will need to refer to them each time the function is inlined.
References add_AT_location_description(), add_const_value_attribute(), cache, decl_by_reference_p(), cached_dw_loc_list_def::decl_id, dw_loc_list_struct::dw_loc_next, var_loc_list_def::first, var_loc_node::loc, cached_dw_loc_list_def::loc_list, loc_list_from_tree(), lookup_decl_loc(), var_loc_node::next, rtl_for_decl_location(), and tree_add_const_value_attribute_for_decl().
Referenced by dwarf2out_finish(), gen_formal_parameter_die(), and gen_variable_die().
|
static |
|
static |
Add a DW_AT_name attribute and source coordinate attribute for the given decl, but only if it actually has a name.
References add_AT_addr(), add_linkage_name(), add_name_attribute(), add_src_coords_attributes(), decl_name(), dwarf2_name(), and vec_safe_push().
|
static |
Referenced by add_name_and_src_coords_attributes(), dwarf2out_finish(), dwarf2out_set_name(), dwarf2out_vms_debug_main_pointer(), gen_array_type_die(), gen_compile_unit_die(), gen_descr_array_type_die(), gen_enumeration_type_die(), gen_namespace_die(), gen_struct_or_union_type_die(), gen_subprogram_die(), gen_type_die_with_usage(), and modified_type_die().
|
static |
Generate a DW_AT_name attribute given some string value to be included as the value of the attribute.
References add_AT_string(), and demangle_name_func.
|
static |
Referenced by gen_subprogram_die(), and gen_subroutine_type_die().
|
inlinestatic |
If the compiled language is ANSI C, then add a 'prototyped' attribute, if arg types are given for the parameters of a function.
References add_AT_flag(), comp_unit_die(), get_AT_unsigned(), and prototype_p().
|
static |
Referenced by gen_subprogram_die(), and gen_variable_die().
|
static |
|
static |
Referenced by add_pubname(), gen_namespace_die(), gen_subprogram_die(), and gen_variable_die().
|
static |
Add a new entry to .debug_pubnames if appropriate.
References pubname_struct::die, pubname_struct::name, and vec_safe_push().
|
static |
|
static |
Add a new entry to .debug_pubtypes if appropriate.
References add_enumerator_pubname(), pubname_struct::die, die_struct::die_parent, die_struct::die_tag, lang_hooks::dwarf_name, is_cu_die(), is_cxx(), is_namespace_die(), pubname_struct::name, type_tag(), vec_safe_push(), and want_pubnames().
|
static |
Referenced by gen_subprogram_die().
|
inlinestatic |
We do not currently support the pure_virtual attribute.
References add_AT_die_ref(), add_AT_loc(), add_AT_unsigned(), DINFO_LEVEL_TERSE, host_integerp(), lookup_type_die(), new_loc_descr(), and tree_low_cst().
|
static |
Referenced by add_high_low_attributes(), dwarf2out_finish(), and gen_subprogram_die().
|
static |
Add a new entry to .debug_ranges corresponding to a block, or a range terminator if BLOCK is NULL.
References add_ranges_num().
|
static |
Add a new entry to .debug_ranges corresponding to a pair of labels. When using dwarf_split_debug_info, address attributes in dies destined for the final executable should be direct references--setting the parameter force_direct ensures this behavior.
References add_AT_range_list(), add_ranges_num(), dw_ranges_by_label_struct::begin, dw_ranges_by_label_struct::end, memset(), offset, and ranges_by_label_in_use.
Referenced by dwarf2out_finish(), and gen_subprogram_die().
|
static |
Referenced by add_ranges(), and add_ranges_by_labels().
|
static |
Add a new entry to .debug_ranges. Return the offset at which it was placed.
References memset(), dw_ranges_struct::num, and ranges_table_in_use.
|
static |
Referenced by add_sibling_attributes(), and dwarf2out_finish().
|
static |
Traverse the DIE and add a sibling attribute if it may have the effect of speeding up access to siblings. To save some space, avoid generating sibling attributes for DIE's without children.
References add_AT_die_ref(), add_sibling_attributes(), die_struct::die_child, die_struct::die_parent, and die_struct::die_sib.
|
inlinestatic |
Add a string attribute value to a skeleton DIE.
References add_dwarf_attr(), debug_str_do_hash(), debug_str_eq(), dw_attr_struct::dw_attr, dw_attr_struct::dw_attr_val, dw_val_class_str, find_AT_string_in_table(), find_string_form(), indirect_string_node::form, dw_val_struct::v, dw_val_struct::val_class, dw_val_struct::val_entry, and dw_val_struct::dw_val_struct_union::val_str.
Referenced by add_top_level_skeleton_die_attrs().
|
static |
|
static |
Add source coordinate attributes for the given decl.
References add_AT_file(), add_AT_unsigned(), expand_location(), and lookup_filename().
|
static |
Referenced by gen_array_type_die().
|
static |
Add subscript info to TYPE_DIE, describing an array TYPE, collapsing possibly nested array subscripts in a flat sequence if COLLAPSE_P is true. Note that the block of subscript information for an array type also includes information about the element type of the given array type.
References add_bound_info(), add_type_attribute(), is_fortran(), and new_die().
|
static |
Helper function to generate top-level dies for skeleton debug_info and debug_types.
References add_AT_lineptr(), add_AT_pubnames(), add_skeleton_AT_string(), and comp_dir_string().
Referenced by dwarf2out_finish(), and get_skeleton_type_unit().
|
static |
Many forms of DIEs require a "type description" attribute. This routine locates the proper "type descriptor" die for the type given by 'type', and adds a DW_AT_type attribute below the given die.
References add_AT_die_ref(), and modified_type_die().
Referenced by add_bound_info(), add_subscript_info(), gen_array_type_die(), gen_const_die(), gen_descr_array_type_die(), gen_entry_point_die(), gen_field_die(), gen_formal_parameter_die(), gen_inheritance_die(), gen_pointer_type_die(), gen_ptr_to_mbr_type_die(), gen_reference_type_die(), gen_subprogram_die(), gen_subroutine_type_die(), gen_typedef_die(), gen_variable_die(), and generic_parameter_die().
|
staticread |
Referenced by dwarf2out_var_location().
|
staticread |
Add a variable location node to the linked list for DECL.
References adjust_piece_list(), construct_piece_list(), var_loc_list_def::decl_id, decl_loc_table, decl_piece_bitsize(), decl_piece_varloc_ptr(), var_loc_list_def::first, get_ref_base_and_extent(), ggc_free(), handled_component_p(), var_loc_node::label, last, var_loc_list_def::last, var_loc_node::loc, memset(), var_loc_node::next, prev_real_insn(), rtx_equal_p(), and VAR_INIT_STATUS_UNINITIALIZED.
|
static |
Hash an address_table_entry.
References addr_table_entry_struct::addr, ate_kind_label, ate_kind_rtx, ate_kind_rtx_dtprel, iterative_hash_rtx(), addr_table_entry_struct::kind, addr_table_entry_struct::addr_table_entry_struct_union::label, and addr_table_entry_struct::addr_table_entry_struct_union::rtl.
Referenced by add_addr_table_entry().
|
static |
Determine equality for two address_table_entries.
References addr_table_entry_struct::addr, ate_kind_label, ate_kind_rtx, ate_kind_rtx_dtprel, addr_table_entry_struct::kind, addr_table_entry_struct::addr_table_entry_struct_union::label, addr_table_entry_struct::addr_table_entry_struct_union::rtl, and rtx_equal_p().
Referenced by add_addr_table_entry().
|
static |
Return loc description representing "address" of integer value. This can appear only as toplevel expression.
References add_loc_descr(), dw_loc_descr_struct::dw_loc_oprnd2, dw_val_class_const, int_loc_descriptor(), new_loc_descr(), size_of_int_loc_descriptor(), dw_val_struct::v, dw_val_struct::val_class, and dw_val_struct::dw_val_struct_union::val_int.
Referenced by loc_descriptor(), and loc_list_from_tree().
|
static |
This function either modifies location piece list *DEST in place (if SRC and INNER is NULL), or copies location piece list *SRC to *DEST while modifying it. Location BITPOS is modified to contain LOC_NOTE, any pieces overlapping it are removed resp. not copied and if needed some padding around it is added. When modifying in place, DEST should point to EXPR_LIST where earlier pieces cover PIECE_BITPOS bits, when copying SRC points to the start of the whole list and INNER points to the EXPR_LIST where earlier pieces cover PIECE_BITPOS bits.
References copy(), decl_piece_bitsize(), decl_piece_node(), decl_piece_varloc_ptr(), and free_EXPR_LIST_node().
Referenced by add_var_loc_to_decl().
|
static |
Referenced by generic_parameter_die().
|
static |
Schedule generation of a DW_AT_const_value attribute to DIE. That generation should happen after function debug info has been generated. The value of the attribute is the constant value of ARG.
References die_arg_entry_struct::arg, die_arg_entry_struct::die, vec_alloc(), and vec_safe_push().
|
static |
Referenced by assign_symbol_names(), and break_out_includes().
|
static |
Assign symbols to all worthy DIEs under DIE.
References assign_symbol_names(), die_struct::comdat_type_p, die_struct::die_id, die_struct::die_symbol_or_type_node::die_symbol, gen_internal_sym(), is_symbol_die(), and strlen().
|
inlinestatic |
Referenced by attr_checksum(), attr_checksum_ordered(), and output_attr_index_or_value().
|
inlinestatic |
Get the RTX from to an address DIE attribute.
References AT_class(), dw_attr_struct::dw_attr_val, dw_val_class_addr, dw_val_struct::v, and dw_val_struct::dw_val_struct_union::val_addr.
|
inlinestatic |
Referenced by AT_addr(), AT_file(), AT_flag(), AT_index(), AT_int(), AT_lbl(), AT_loc(), AT_loc_list(), AT_loc_list_ptr(), AT_ref(), AT_ref_external(), AT_string(), AT_string_form(), AT_unsigned(), AT_vms_delta1(), AT_vms_delta2(), attr_checksum(), attr_checksum_ordered(), build_abbrev_table(), copy_decls_walk(), index_location_lists(), optimize_external_refs_1(), optimize_location_lists_1(), output_attr_index_or_value(), output_die(), output_location_lists(), print_die(), prune_unused_types_update_strings(), prune_unused_types_walk_attribs(), remove_AT(), resolve_addr(), set_AT_ref_external(), size_of_die(), unmark_all_dies(), and value_format().
|
inlinestatic |
References dw_attr_struct::dw_attr_val, and dw_val_struct::val_class.
|
staticread |
Get the dwarf_file_data from a file DIE attribute.
References AT_class(), dw_attr_struct::dw_attr_val, dw_val_class_file, dw_val_struct::v, and dw_val_struct::dw_val_struct_union::val_file.
Referenced by attr_checksum(), attr_checksum_ordered(), get_AT_file(), and print_die().
|
inlinestatic |
Referenced by get_AT_flag(), output_die(), and print_die().
|
inlinestatic |
|
inlinestatic |
Referenced by output_attr_index_or_value(), output_die(), resolve_addr(), size_of_die(), and value_format().
|
inlinestatic |
Return the index for any attribute that will be referenced with a DW_FORM_GNU_addr_index or DW_FORM_GNU_str_index. String indices are stored in dw_attr_val.v.val_str for reference counting pruning.
References AT_class(), dw_attr_struct::dw_attr_val, dw_val_class_str, indirect_string_node::index, addr_table_entry_struct::index, dw_val_struct::v, dw_val_struct::val_entry, and dw_val_struct::dw_val_struct_union::val_str.
|
inlinestatic |
Referenced by output_die(), print_die(), and size_of_die().
|
inlinestatic |
|
inlinestatic |
Referenced by get_AT_hi_pc(), get_AT_low_pc(), output_attr_index_or_value(), output_die(), and print_die().
|
inlinestatic |
|
inlinestatic |
Referenced by attr_checksum(), attr_checksum_ordered(), output_die(), resolve_addr(), size_of_die(), and value_format().
|
inlinestatic |
|
inlinestatic |
Referenced by index_location_lists(), optimize_location_lists_1(), output_loc_list_offset(), output_location_lists(), and print_die().
|
inlinestatic |
|
inlinestatic |
References AT_class(), dw_attr_struct::dw_attr_val, dw_val_class_loc_list, dw_val_struct::v, and dw_val_struct::dw_val_struct_union::val_loc_list.
Referenced by resolve_addr().
|
inlinestatic |
|
inlinestatic |
|
inlinestatic |
Referenced by output_die(), size_of_die(), and value_format().
|
inlinestatic |
|
inlinestatic |
Referenced by attr_checksum(), attr_checksum_ordered(), die_checksum_ordered(), get_AT_string(), output_die(), and print_die().
|
inlinestatic |
|
static |
Referenced by size_of_die(), and value_format().
|
static |
Find out whether the string referenced from the attribute should be output inline in DIE or out-of-line in .debug_str section.
References AT_class(), dw_attr_struct::dw_attr_val, dw_val_class_str, find_string_form(), dw_val_struct::v, and dw_val_struct::dw_val_struct_union::val_str.
|
inlinestatic |
Referenced by get_AT_unsigned(), output_die(), print_die(), size_of_die(), and value_format().
|
inlinestatic |
|
inlinestatic |
Referenced by output_die(), and print_die().
|
inlinestatic |
Return the start label of a delta attribute.
References AT_class(), dw_attr_struct::dw_attr_val, dw_val_class_vms_delta, dw_val_struct::dw_val_struct_union::dw_val_vms_delta_union::lbl1, dw_val_struct::v, and dw_val_struct::dw_val_struct_union::val_vms_delta.
|
inlinestatic |
Referenced by output_die(), and print_die().
|
inlinestatic |
Return the end label of a delta attribute.
References AT_class(), dw_attr_struct::dw_attr_val, dw_val_class_vms_delta, dw_val_struct::dw_val_struct_union::dw_val_vms_delta_union::lbl2, dw_val_struct::v, and dw_val_struct::dw_val_struct_union::val_vms_delta.
|
static |
Referenced by die_checksum().
|
static |
Calculate the checksum of an attribute.
References dw_vec_struct::array, AT_addr(), AT_class(), AT_file(), AT_loc(), AT_ref(), AT_string(), die_checksum(), dw_attr_struct::dw_attr, dw_attr_struct::dw_attr_val, dw_loc_descr_struct::dw_loc_next, dw_val_class_addr, dw_val_class_const, dw_val_class_const_double, dw_val_class_data8, dw_val_class_die_ref, dw_val_class_fde_ref, dw_val_class_file, dw_val_class_flag, dw_val_class_high_pc, dw_val_class_lbl_id, dw_val_class_lineptr, dw_val_class_loc, dw_val_class_macptr, dw_val_class_offset, dw_val_class_str, dw_val_class_unsigned_const, dw_val_class_vec, dw_val_class_vms_delta, dw_vec_struct::elt_size, dw_vec_struct::length, loc_checksum(), dw_val_struct::v, dw_val_struct::dw_val_struct_union::val_data8, dw_val_struct::dw_val_struct_union::val_double, dw_val_struct::dw_val_struct_union::val_flag, dw_val_struct::dw_val_struct_union::val_int, dw_val_struct::dw_val_struct_union::val_offset, dw_val_struct::dw_val_struct_union::val_unsigned, and dw_val_struct::dw_val_struct_union::val_vec.
|
static |
Calculate the checksum of an attribute.
References dw_vec_struct::array, AT_addr(), AT_class(), AT_file(), AT_loc(), AT_ref(), AT_string(), checksum_die_context(), die_checksum_ordered(), die_struct::die_mark, die_struct::die_parent, dw_attr_struct::dw_attr, dw_attr_struct::dw_attr_val, dw_loc_descr_struct::dw_loc_next, dw_val_class_addr, dw_val_class_const, dw_val_class_const_double, dw_val_class_data8, dw_val_class_die_ref, dw_val_class_fde_ref, dw_val_class_file, dw_val_class_flag, dw_val_class_high_pc, dw_val_class_lbl_id, dw_val_class_lineptr, dw_val_class_loc, dw_val_class_macptr, dw_val_class_offset, dw_val_class_str, dw_val_class_unsigned_const, dw_val_class_vec, dw_vec_struct::elt_size, get_AT(), get_AT_ref(), dw_vec_struct::length, loc_checksum_ordered(), dw_val_struct::v, dw_val_struct::dw_val_struct_union::val_data8, dw_val_struct::dw_val_struct_union::val_double, dw_val_struct::dw_val_struct_union::val_flag, dw_val_struct::dw_val_struct_union::val_int, dw_val_struct::dw_val_struct_union::val_offset, dw_val_struct::dw_val_struct_union::val_unsigned, and dw_val_struct::dw_val_struct_union::val_vec.
|
static |
Comparison function for sorting marked base types.
References die_struct::die_mark, and get_AT_unsigned().
Referenced by move_marked_base_types().
|
static |
Referenced by modified_type_die().
|
static |
Given a pointer to a tree node for some base type, return a pointer to a DIE that describes the given type. This routine must only be called for GCC type nodes that correspond to Dwarf base (fundamental) types.
References add_AT_unsigned(), add_pubtype(), comp_unit_die(), int_size_in_bytes(), and new_die().
|
static |
Return a reference to DW_TAG_base_type corresponding to MODE and UNSIGNEDP if possible, NULL otherwise.
References comp_unit_die(), die_struct::die_tag, lookup_type_die(), modified_type_die(), lang_hooks_for_types::type_for_mode, and lang_hooks::types.
Referenced by convert_descriptor_to_mode(), mem_loc_descriptor(), minmax_loc_descriptor(), and scompare_loc_descriptor().
|
static |
Return a location descriptor that designates a base+offset location.
References add_loc_descr(), cfun, dw_fde_struct::drap_reg, eliminate_regs(), function::fde, frame_pointer_fb_offset, ira_use_lra_p, lra_eliminate_regs(), new_loc_descr(), new_reg_loc_descr(), VAR_INIT_STATUS_UNINITIALIZED, and dw_fde_struct::vdrap_reg.
Referenced by mem_loc_descriptor().
|
static |
Referenced by break_out_comdat_types(), and dwarf2out_finish().
|
static |
Traverse the DIE and set up additional .debug_types sections for each type worthy of being placed in a COMDAT section.
References add_AT_unsigned(), add_child_die(), break_out_comdat_types(), comdat_type_list, comp_unit_die(), die_struct::die_child, die_struct::die_sib, die_struct::die_tag, first, generate_type_signature(), get_AT_unsigned(), new_die(), comdat_type_struct::next, remove_child_or_replace_with_skeleton(), comdat_type_struct::root_die, should_move_die_to_comdat(), and comdat_type_struct::skeleton_die.
|
static |
Referenced by dwarf2out_finish().
|
static |
Traverse the DIE (which is always comp_unit_die), and set up additional compilation units for each of the include files we see bracketed by BINCL/EINCL.
References add_child_die(), assign_symbol_names(), check_duplicate_cu(), compute_section_prefix(), hash_table< Descriptor, Allocator >::create(), limbo_die_struct::die, die_struct::die_child, die_struct::die_sib, die_struct::die_tag, hash_table< Descriptor, Allocator >::dispose(), is_comdat_die(), limbo_die_list, limbo_die_struct::next, pop_compile_unit(), push_new_compile_unit(), record_comdat_symbol_number(), and remove_child_with_prev().
|
static |
BSWAP (constS is initial shift count, either 56 or 24): constS const0 L1: DW_OP_pick <2> constS DW_OP_pick <3> DW_OP_minus DW_OP_shr const255 DW_OP_and DW_OP_pick <2> DW_OP_shl DW_OP_or DW_OP_swap DW_OP_dup const0 DW_OP_eq DW_OP_bra <L2> const8 DW_OP_minus DW_OP_swap DW_OP_skip <L1> L2: DW_OP_drop DW_OP_swap DW_OP_drop
References add_loc_descr(), dw_loc_descr_struct::dw_loc_oprnd1, dw_val_class_loc, mem_loc_descriptor(), new_loc_descr(), dw_val_struct::v, dw_val_struct::val_class, dw_val_struct::dw_val_struct_union::val_loc, and VAR_INIT_STATUS_INITIALIZED.
Referenced by mem_loc_descriptor().
|
static |
The format of each DIE (and its attribute value pairs) is encoded in an abbreviation table. This routine builds the abbreviation table and assigns a unique abbreviation id for each abbreviation entry. The children of each die are visited recursively.
References abbrev_die_table_in_use, AT_class(), AT_ref(), change_AT_die_ref(), die_struct::die_abbrev, die_struct::die_attr, die_struct::die_child, die_struct::die_tag, dw_attr_struct::dw_attr, dw_val_class_die_ref, lookup_external_ref(), memset(), set_AT_ref_external(), external_ref::stub, value_format(), and vec_safe_length().
Referenced by output_comdat_type_unit(), and output_comp_unit().
|
read |
This function builds a dwarf location descriptor sequence for the address at OFFSET from the CFA when stack is aligned to ALIGNMENT byte.
References add_loc_descr(), cfa_loc::indirect, int_loc_descriptor(), loc_descr_plus_const(), new_loc_descr(), new_reg_loc_descr(), and cfa_loc::reg.
Referenced by reg_save().
|
read |
This function builds a dwarf location descriptor sequence from a dw_cfa_location, adding the given OFFSET to the result of the expression.
References add_loc_descr(), cfa_loc::base_offset, dw_loc_descr_struct::dw_loc_oprnd1, dw_val_class_const, cfa_loc::indirect, new_loc_descr(), new_reg_loc_descr(), cfa_loc::offset, cfa_loc::reg, dw_val_struct::val_class, and dw_val_struct::val_entry.
Referenced by convert_cfa_to_fb_loc_list(), and def_cfa_0().
|
static |
Return nonzero if decl_id of cached_dw_loc_list X is the same as UID of decl *Y.
Referenced by dwarf2out_init().
|
static |
Returns a hash value for X (which really is a cached_dw_loc_list_list).
Referenced by dwarf2out_init().
|
static |
Size just the base type children at the start of the CU. This is needed because build_abbrev needs to size locs and sizing of type based stack ops needs to know die_offset values for the base types.
References comp_unit_die(), die_struct::die_abbrev, die_struct::die_child, die_struct::die_offset, die_struct::die_sib, and size_of_die().
Referenced by get_base_type_offset().
|
static |
Referenced by calc_die_sizes(), output_comdat_type_unit(), and output_comp_unit().
|
static |
Size the debugging information associated with a given DIE. Visits the DIE's children recursively. Updates the global variable next_die_offset, on each time through. Uses the current value of next_die_offset to update the die_offset field in each DIE.
References calc_die_sizes(), die_struct::die_child, die_struct::die_offset, next_die_offset, and size_of_die().
|
static |
|
inlinestatic |
Given a value, round it up to the lowest multiple of `boundary' which is not less than the value itself.
|
inlinestatic |
Change DIE reference REF to point to NEW_DIE instead.
References dw_val_struct::dw_val_struct_union::dw_val_die_union::die, dw_attr_struct::dw_attr_val, dw_val_class_die_ref, dw_val_struct::dw_val_struct_union::dw_val_die_union::external, new_die(), dw_val_struct::v, dw_val_struct::val_class, and dw_val_struct::dw_val_struct_union::val_die_ref.
Referenced by build_abbrev_table().
|
static |
Check whether we have already seen this CU and set up SYM_NUM accordingly.
References die_struct::die_id, die_struct::die_symbol_or_type_node::die_symbol, hash_table< Descriptor, Allocator >::find_slot_with_hash(), cu_hash_table_entry::max_comdat_num, cu_hash_table_entry::min_comdat_num, cu_hash_table_entry::next, and same_die_p_wrap().
Referenced by break_out_includes().
|
static |
Referenced by attr_checksum_ordered(), checksum_die_context(), and generate_type_signature().
|
static |
Checksum the context of the DIE. This adds the names of any surrounding namespaces or structures to the checksum.
References checksum_die_context(), die_struct::die_parent, die_struct::die_tag, get_AT_ref(), and get_AT_string().
|
static |
|
static |
Calculate the checksum of a number in signed LEB128 format.
|
static |
Referenced by optimize_macinfo_range().
|
static |
Calculate the checksum of a number in unsigned LEB128 format.
|
inlinestatic |
Referenced by gen_decl_die(), gen_subprogram_die(), and gen_variable_die().
|
inlinestatic |
Returns nonzero if CONTEXT_DIE is a class or namespace, for deciding whether or not to treat a DIE in this context as a declaration.
References class_scope_p(), and die_struct::die_tag.
|
inlinestatic |
Referenced by add_pubname(), class_or_namespace_scope_p(), gen_variable_die(), and prune_unused_types_mark().
|
inlinestatic |
Returns nonzero if CONTEXT_DIE is a class.
References die_struct::die_tag.
|
static |
Referenced by copy_ancestor_tree(), generate_skeleton(), and generate_skeleton_ancestor_tree().
|
static |
Make a clone of DIE as a declaration.
References add_AT_die_ref(), add_AT_flag(), add_dwarf_attr(), clone_die(), die_struct::comdat_type_p, die_struct::die_attr, die_struct::die_tag, dw_attr_struct::dw_attr, get_AT_ref(), and is_declaration_die().
|
static |
Referenced by clone_as_declaration(), clone_tree(), clone_tree_hash(), copy_decls_walk(), and generate_skeleton_bottom_up().
|
static |
Make a clone of DIE.
References add_dwarf_attr(), die_struct::die_attr, and die_struct::die_tag.
|
static |
Referenced by clone_tree(), and copy_declaration_context().
|
static |
Make a clone of the tree rooted at DIE.
References add_child_die(), clone_die(), and clone_tree().
|
static |
Like clone_tree, but additionally enter all the children into the hash table decl_table.
References add_child_die(), clone_die(), decl_table_entry::copy, hash_table< Descriptor, Allocator >::find_slot_with_hash(), and decl_table_entry::orig.
Referenced by copy_decls_walk().
|
static |
CLZ (where constV is CLZ_DEFINED_VALUE_AT_ZERO computed value, const0 is DW_OP_lit0 or corresponding typed constant, const1 is DW_OP_lit1 or corresponding typed constant and constMSB is constant with just the MSB bit set for the mode): DW_OP_dup DW_OP_bra <L1> DW_OP_drop constV DW_OP_skip <L4> L1: const0 DW_OP_swap L2: DW_OP_dup constMSB DW_OP_and DW_OP_bra <L3> const1 DW_OP_shl DW_OP_swap DW_OP_plus_uconst <1> DW_OP_swap DW_OP_skip <L2> L3: DW_OP_drop L4: DW_OP_nop CTZ is similar: DW_OP_dup DW_OP_bra <L1> DW_OP_drop constV DW_OP_skip <L4> L1: const0 DW_OP_swap L2: DW_OP_dup const1 DW_OP_and DW_OP_bra <L3> const1 DW_OP_shr DW_OP_swap DW_OP_plus_uconst <1> DW_OP_swap DW_OP_skip <L2> L3: DW_OP_drop L4: DW_OP_nop FFS is similar: DW_OP_dup DW_OP_bra <L1> DW_OP_drop const0 DW_OP_skip <L4> L1: const1 DW_OP_swap L2: DW_OP_dup const1 DW_OP_and DW_OP_bra <L3> const1 DW_OP_shr DW_OP_swap DW_OP_plus_uconst <1> DW_OP_swap DW_OP_skip <L2> L3: DW_OP_drop L4: DW_OP_nop
References add_loc_descr(), dw_loc_descr_struct::dw_loc_oprnd1, dw_val_class_loc, HOST_BITS_PER_WIDE_INT, immed_double_const(), mem_loc_descriptor(), new_loc_descr(), dw_val_struct::v, dw_val_struct::val_class, dw_val_struct::dw_val_struct_union::val_loc, and VAR_INIT_STATUS_INITIALIZED.
Referenced by mem_loc_descriptor().
|
static |
Referenced by die_checksum_ordered().
|
static |
Collect the attributes that we will want to use for the checksum.
References checksum_attributes::at_accessibility, checksum_attributes::at_address_class, checksum_attributes::at_allocated, checksum_attributes::at_artificial, checksum_attributes::at_associated, checksum_attributes::at_binary_scale, checksum_attributes::at_bit_offset, checksum_attributes::at_bit_size, checksum_attributes::at_bit_stride, checksum_attributes::at_byte_size, checksum_attributes::at_byte_stride, checksum_attributes::at_const_value, checksum_attributes::at_containing_type, checksum_attributes::at_count, checksum_attributes::at_data_location, checksum_attributes::at_data_member_location, checksum_attributes::at_decimal_scale, checksum_attributes::at_decimal_sign, checksum_attributes::at_default_value, checksum_attributes::at_digit_count, checksum_attributes::at_discr, checksum_attributes::at_discr_list, checksum_attributes::at_discr_value, checksum_attributes::at_encoding, checksum_attributes::at_endianity, checksum_attributes::at_explicit, checksum_attributes::at_friend, checksum_attributes::at_is_optional, checksum_attributes::at_location, checksum_attributes::at_lower_bound, checksum_attributes::at_mutable, checksum_attributes::at_name, checksum_attributes::at_ordering, checksum_attributes::at_picture_string, checksum_attributes::at_prototyped, checksum_attributes::at_segment, checksum_attributes::at_small, checksum_attributes::at_string_length, checksum_attributes::at_threads_scaled, checksum_attributes::at_type, checksum_attributes::at_upper_bound, checksum_attributes::at_use_location, checksum_attributes::at_use_UTF8, checksum_attributes::at_variable_parameter, checksum_attributes::at_virtuality, checksum_attributes::at_visibility, checksum_attributes::at_vtable_elem_location, die_struct::die_attr, and dw_attr_struct::dw_attr.
|
static |
Referenced by gen_variable_die().
|
static |
Return nonzero if decl_id and die_parent of die_struct X is the same as decl_id and die_parent of die_struct Y.
References die_struct::decl_id, and die_struct::die_parent.
|
static |
Referenced by gen_variable_die().
|
static |
Returns a hash value for X (which really is a die_struct).
References die_struct::decl_id, and die_struct::die_parent.
|
static |
Retrieve the comp_dir string suitable for use with DW_AT_comp_dir.
References get_src_pwd(), remap_debug_filename(), and strlen().
Referenced by add_comp_dir_attribute(), and add_top_level_skeleton_die_attrs().
|
static |
Return the root of the DIE's built for the current compilation unit.
References gen_compile_unit_die(), and single_comp_unit_die.
Referenced by add_bound_info(), add_prototyped_attribute(), base_type_die(), base_type_for_mode(), break_out_comdat_types(), calc_base_type_die_sizes(), debug_dwarf(), dwarf2out_abstract_function(), dwarf2out_decl(), dwarf2out_end_source_file(), dwarf2out_finish(), dwarf2out_start_source_file(), dwarf2out_vms_debug_main_pointer(), force_decl_die(), gen_namespace_die(), gen_type_die_with_usage(), get_base_type_offset(), get_context_die(), is_ada(), is_cxx(), is_fortran(), lower_bound_default(), mark_base_types(), move_marked_base_types(), prune_unused_types(), retry_incomplete_types(), scope_die_for(), string_cst_pool_decl(), and subrange_type_die().
|
static |
Return location descriptor for comparison OP with operands OP0 and OP1.
References add_loc_descr(), int_loc_descriptor(), and new_loc_descr().
Referenced by scompare_loc_descriptor(), and ucompare_loc_descriptor().
|
inlinestatic |
Return true if X and Y opcodes have the same operands.
References addr_table_entry_struct::addr, dw_vec_struct::array, dw_val_struct::dw_val_struct_union::dw_val_die_union::die, dw_loc_descr_struct::dtprel, dw_loc_descr_struct::dw_loc_addr, dw_loc_descr_struct::dw_loc_oprnd1, dw_loc_descr_struct::dw_loc_oprnd2, dw_val_class_addr, dw_val_class_const, dw_val_class_const_double, dw_val_class_die_ref, dw_val_class_loc, dw_val_class_unsigned_const, dw_val_class_vec, dw_vec_struct::elt_size, double_int::high, dw_vec_struct::length, double_int::low, addr_table_entry_struct::addr_table_entry_struct_union::rtl, rtx_equal_p(), dw_val_struct::v, dw_val_struct::dw_val_struct_union::val_addr, dw_val_struct::val_class, dw_val_struct::dw_val_struct_union::val_die_ref, dw_val_struct::dw_val_struct_union::val_double, dw_val_struct::val_entry, dw_val_struct::dw_val_struct_union::val_int, dw_val_struct::dw_val_struct_union::val_loc, dw_val_struct::dw_val_struct_union::val_unsigned, and dw_val_struct::dw_val_struct_union::val_vec.
Referenced by compare_locs().
|
inlinestatic |
Return true if DWARF location expressions X and Y are the same.
References compare_loc_operands(), dw_loc_descr_struct::dtprel, and dw_loc_descr_struct::dw_loc_next.
Referenced by loc_list_hasher::equal().
|
static |
Compute a displacement from the "steady-state frame pointer" to the frame base (often the same as the CFA), and store it in frame_pointer_fb_offset. OFFSET is added to the displacement before the latter is negated.
References current_function_decl, eliminate_regs(), ira_use_lra_p, lra_eliminate_regs(), and offset.
Referenced by gen_subprogram_die().
|
static |
Referenced by break_out_includes().
|
static |
Calculate the MD5 checksum of the compilation unit DIE UNIT_DIE and its children, and set comdat_symbol_id accordingly.
References clean_symbol_name(), die_checksum(), die_struct::die_id, die_struct::die_symbol_or_type_node::die_symbol, get_AT_string(), strlen(), and unmark_all_dies().
|
static |
Referenced by loc_descriptor().
|
static |
Return a descriptor that describes the concatenation of two locations. This is typically a complex variable.
References add_loc_descr(), add_loc_descr_op_piece(), loc_descriptor(), new_loc_descr(), VAR_INIT_STATUS_INITIALIZED, and VAR_INIT_STATUS_UNINITIALIZED.
|
static |
Return a descriptor that describes the concatenation of N locations.
References add_loc_descr(), add_loc_descr_op_piece(), loc_descriptor(), new_loc_descr(), VAR_INIT_STATUS_INITIALIZED, and VAR_INIT_STATUS_UNINITIALIZED.
Referenced by loc_descriptor().
|
static |
Return true if constant RTL can be emitted in DW_OP_addr or DW_AT_const_value. TLS SYMBOL_REFs, external SYMBOL_REFs or non-marked constant pool SYMBOL_REFs can't be referenced in it.
References const_ok_for_output_1(), and for_each_rtx().
Referenced by add_const_value_attribute(), loc_descriptor(), loc_list_from_tree(), and mem_loc_descriptor().
|
static |
Helper function for const_ok_for_output, called either directly or via for_each_rtx.
References current_function_decl, expansion_failed(), get_pool_constant_mark(), inform(), marked, targetm, and TLS_MODEL_NONE.
Referenced by const_ok_for_output().
|
static |
Referenced by output_die(), size_of_die(), and value_format().
|
static |
Return the power-of-two number of bytes necessary to represent VALUE.
References floor_log2(), and log().
|
static |
Return rtx that should be stored into loc field for LOC_NOTE and BITPOS/BITSIZE.
References decl_piece_node().
Referenced by add_var_loc_to_decl().
|
static |
Return non-zero if this DIE contains a defining declaration of a subprogram.
References die_struct::die_tag, and is_declaration_die().
Referenced by should_move_die_to_comdat().
|
static |
Convert the CFI instructions for the current function into a location list. This is used for DW_AT_frame_base when we targeting a dwarf2 consumer that does not support the dwarf3 DW_OP_call_frame_cfa. OFFSET is a constant to be added to all CFA expressions.
References build_cfa_loc(), cfa_equal_p(), cfun, cie_cfi_vec, current_function_decl, dw_cfi_oprnd_struct::dw_cfi_addr, dw_cfi_struct::dw_cfi_opc, dw_cfi_struct::dw_cfi_oprnd1, dw_fde_struct::dw_fde_begin, dw_fde_struct::dw_fde_cfi, dw_fde_struct::dw_fde_end, dw_fde_struct::dw_fde_second_begin, dw_fde_struct::dw_fde_second_end, dw_fde_struct::dw_fde_switch_cfi_index, dw_loc_list_struct::dw_loc_next, function::fde, gen_llsym(), lookup_cfa_1(), memset(), new_loc_list(), cfa_loc::reg, and secname_for_decl().
Referenced by gen_subprogram_die().
|
static |
For OP descriptor assumed to be in unsigned MODE, convert it to a unsigned type matching MODE, or, if MODE is narrower than or as wide as DWARF2_ADDR_SIZE, untyped. Return NULL if the conversion is not possible.
References add_loc_descr(), base_type_for_mode(), dw_val_struct::dw_val_struct_union::dw_val_die_union::die, dw_loc_descr_struct::dw_loc_oprnd1, dw_val_class_die_ref, dw_val_struct::dw_val_struct_union::dw_val_die_union::external, new_loc_descr(), dw_val_struct::v, dw_val_struct::val_class, and dw_val_struct::dw_val_struct_union::val_die_ref.
Referenced by mem_loc_descriptor(), minmax_loc_descriptor(), and typed_binop().
|
static |
Copy DIE and its ancestors, up to, but not including, the compile unit or type unit entry, to a new tree. Adds the new tree to UNIT and returns a pointer to the copy of DIE. If DECL_TABLE is provided, it is used to check if the ancestor has already been copied into UNIT.
References add_child_die(), clone_as_declaration(), copy(), decl_table_entry::copy, die_struct::die_parent, hash_table< Descriptor, Allocator >::find_slot_with_hash(), get_AT_ref(), hash_table< Descriptor, Allocator >::is_created(), is_unit_die(), and decl_table_entry::orig.
Referenced by copy_declaration_context(), and copy_decls_walk().
|
static |
Referenced by remove_child_or_replace_with_skeleton().
|
static |
Copy the declaration context to the new type unit DIE. This includes any surrounding namespace or type declarations. If the DIE has an AT_specification attribute, it also includes attributes and children attached to the specification, and returns a pointer to the original parent of the declaration DIE. Returns NULL otherwise.
References add_AT_specification(), add_child_die(), add_dwarf_attr(), clone_tree(), die_struct::comdat_type_p, copy_ancestor_tree(), die_struct::die_attr, die_struct::die_id, die_struct::die_parent, die_struct::die_symbol_or_type_node::die_type_node, dw_attr_struct::dw_attr, get_AT_ref(), is_unit_die(), and remove_AT().
|
static |
Referenced by dwarf2out_finish().
|
static |
Copy declarations for "unworthy" types into the new comdat section. Incomplete types, modified types, and certain other types aren't broken out into comdat sections of their own, so they don't have a signature, and we need to copy the declaration into the same section so that we don't have an external reference.
References copy_decls_walk(), hash_table< Descriptor, Allocator >::create(), decl_table, hash_table< Descriptor, Allocator >::dispose(), mark_dies(), and unmark_dies().
|
static |
Walk the DIE and its children, looking for references to incomplete or trivial types that are unmarked (i.e., that are not in the current type_unit).
References add_child_die(), AT_class(), AT_ref(), clone_die(), clone_tree_hash(), die_struct::comdat_type_p, copy(), decl_table_entry::copy, copy_ancestor_tree(), dw_val_struct::dw_val_struct_union::dw_val_die_union::die, die_struct::die_attr, die_struct::die_mark, die_struct::die_parent, dw_attr_struct::dw_attr_val, dw_val_class_die_ref, hash_table< Descriptor, Allocator >::find_slot_with_hash(), is_unit_die(), mark_dies(), decl_table_entry::orig, dw_val_struct::v, and dw_val_struct::dw_val_struct_union::val_die_ref.
Referenced by copy_decls_for_unworthy_types().
|
static |
LOC is constant expression. Try a luck, look it up in constant pool and return its loc_descr of its address.
References expansion_failed(), get_address_mode(), lookup_constant_def(), mem_loc_descriptor(), and VAR_INIT_STATUS_INITIALIZED.
Referenced by loc_list_from_tree().
|
static |
Referenced by mem_loc_descriptor(), multiple_reg_loc_descriptor(), and reg_loc_descriptor().
|
static |
Return the DBX register number described by a given RTL node.
DEBUG_FUNCTION void debug | ( | ) |
References print_die().
DEBUG_FUNCTION void debug_dwarf | ( | void | ) |
Print all DWARF information collected for the compilation unit. This routine is a debugging aid only.
References comp_unit_die(), and print_die().
DEBUG_FUNCTION void debug_dwarf_die | ( | ) |
Print the information collected for a given DIE.
References print_die().
|
static |
Referenced by add_skeleton_AT_string(), and find_AT_string().
|
static |
Hash and equality functions for debug_str_hash.
|
static |
Referenced by add_skeleton_AT_string(), and find_AT_string().
|
static |
|
static |
Return true when DECL_BY_REFERENCE is defined and set for DECL.
Referenced by add_location_or_const_value_attribute(), gen_decl_die(), gen_formal_parameter_die(), and gen_variable_die().
Referenced by dwarf2out_abstract_function(), and gen_decl_die().
|
static |
Get the class to which DECL belongs, if any. In g++, the DECL_CONTEXT of a virtual function may refer to a base class, so we check the 'this' parameter.
|
static |
Referenced by dwarf2out_init().
|
static |
Return nonzero if decl_id of die_struct X is the same as UID of decl *Y.
|
static |
Referenced by dwarf2out_init().
|
static |
Returns a hash value for X (which really is a die_struct).
|
static |
Referenced by dwarf2out_init().
|
static |
Return nonzero if decl_id of var_loc_list X is the same as UID of decl *Y.
|
static |
Referenced by dwarf2out_init().
|
static |
Returns a hash value for X (which really is a var_loc_list).
|
static |
Return how many bits covers PIECE EXPR_LIST.
Referenced by add_var_loc_to_decl(), adjust_piece_list(), and dw_sra_loc_expr().
|
static |
Create an EXPR_LIST for location note LOC_NOTE covering BITSIZE bits. Next is the chain of following piece nodes.
References alloc_EXPR_LIST().
Referenced by adjust_piece_list(), and construct_piece_list().
|
static |
Return pointer to the location of location note in PIECE EXPR_LIST.
Referenced by add_var_loc_to_decl(), adjust_piece_list(), and dw_sra_loc_expr().
|
static |
Referenced by gen_entry_point_die().
|
static |
Get the decl's label, as described by its RTL. This may be different from the DECL_NAME name used in the source file.
|
static |
|
static |
Determine the "ultimate origin" of a decl. The decl may be an inlined instance of an inlined instance of a decl which is local to an inline function, so we have to trace all of the way back through the origin chain to find out what sort of node actually served as the original seed for the given block.
|
static |
Referenced by gen_decl_die(), and gen_tagged_type_die().
|
static |
Emit a declaration DIE for THING (which is either a DECL or a tagged type) within its namespace, if appropriate. For compatibility with older debuggers, namespace DIEs only contain declarations; all definitions are emitted at CU scope.
References DINFO_LEVEL_TERSE, gen_decl_die(), gen_type_die(), is_fortran(), and setup_namespace_context().
|
static |
Referenced by gen_block_die(), gen_inlined_subroutine_die(), gen_lexical_block_die(), and gen_subprogram_die().
|
static |
Generate all of the decls declared within a given scope and (recursively) all of its sub-blocks.
References DINFO_LEVEL_TERSE, gen_block_die(), and process_scope_var().
|
static |
Add VARIABLE and DIE into deferred locations list.
References deferred_locations_list, deferred_locations_struct::die, deferred_locations_struct::variable, and vec_safe_push().
Referenced by gen_variable_die().
|
static |
References add_loc_descr(), do_binop(), host_integerp(), int_loc_descriptor(), int_size_in_bytes(), loc_descr_plus_const(), loc_descriptor_from_tree(), new_loc_descr(), and tree_low_cst().
Referenced by add_descr_info_field().
|
static |
Referenced by attr_checksum(), compute_section_prefix(), die_checksum(), and dwarf2out_finish().
|
static |
Calculate the checksum of a DIE.
References attr_checksum(), die_struct::die_attr, die_checksum(), die_struct::die_mark, and die_struct::die_tag.
|
static |
Referenced by attr_checksum_ordered(), die_checksum_ordered(), and generate_type_signature().
|
static |
Calculate the checksum of a DIE, using an ordered subset of attributes.
References checksum_attributes::at_accessibility, checksum_attributes::at_address_class, checksum_attributes::at_allocated, checksum_attributes::at_artificial, checksum_attributes::at_associated, checksum_attributes::at_binary_scale, checksum_attributes::at_bit_offset, checksum_attributes::at_bit_size, checksum_attributes::at_bit_stride, checksum_attributes::at_byte_size, checksum_attributes::at_byte_stride, checksum_attributes::at_const_value, checksum_attributes::at_containing_type, checksum_attributes::at_count, checksum_attributes::at_data_location, checksum_attributes::at_data_member_location, checksum_attributes::at_decimal_scale, checksum_attributes::at_decimal_sign, checksum_attributes::at_default_value, checksum_attributes::at_digit_count, checksum_attributes::at_discr, checksum_attributes::at_discr_list, checksum_attributes::at_discr_value, checksum_attributes::at_encoding, checksum_attributes::at_endianity, checksum_attributes::at_explicit, checksum_attributes::at_friend, checksum_attributes::at_is_optional, checksum_attributes::at_location, checksum_attributes::at_lower_bound, checksum_attributes::at_mutable, checksum_attributes::at_name, checksum_attributes::at_ordering, checksum_attributes::at_picture_string, checksum_attributes::at_prototyped, checksum_attributes::at_segment, checksum_attributes::at_small, AT_string(), checksum_attributes::at_string_length, checksum_attributes::at_threads_scaled, checksum_attributes::at_type, checksum_attributes::at_upper_bound, checksum_attributes::at_use_location, checksum_attributes::at_use_UTF8, checksum_attributes::at_variable_parameter, checksum_attributes::at_virtuality, checksum_attributes::at_visibility, checksum_attributes::at_vtable_elem_location, collect_checksum_attributes(), die_checksum_ordered(), die_struct::die_child, die_struct::die_mark, die_struct::die_sib, die_struct::die_tag, get_AT(), get_AT_ref(), is_template_instantiation(), is_type_die(), and memset().
|
static |
Add a type name and tag to a hash.
Referenced by generate_type_signature().
|
inlinestatic |
Similarly, but return a double_int instead of UHWI.
References double_int::from_uhwi(), and tree_to_double_int().
Referenced by field_byte_offset().
|
static |
References DINFO_USAGE_DFN, and DINFO_USAGE_DIR_USE.
|
inlinestatic |
Return the operator to use for an address of a variable. For dtprel_true, we use DW_OP_const*. For regular variables, which need both link-time relocation and consumer-level relocation (e.g., to account for shared objects loaded at a random address), we use DW_OP_addr*.
References dtprel_true.
Referenced by new_addr_loc_descr().
enum dw_cfi_oprnd_type dw_cfi_oprnd1_desc | ( | ) |
Describe for the GTY machinery what parts of dw_cfi_oprnd1 are used.
References dw_cfi_oprnd_addr, dw_cfi_oprnd_loc, dw_cfi_oprnd_offset, dw_cfi_oprnd_reg_num, and dw_cfi_oprnd_unused.
Referenced by cfi_equal_p().
enum dw_cfi_oprnd_type dw_cfi_oprnd2_desc | ( | ) |
Describe for the GTY machinery what parts of dw_cfi_oprnd2 are used.
References dw_cfi_oprnd_loc, dw_cfi_oprnd_offset, dw_cfi_oprnd_reg_num, and dw_cfi_oprnd_unused.
Referenced by cfi_equal_p().
|
static |
Return the dwarf representation of the location list LOC_LIST of DECL. WANT_ADDRESS has the same meaning as in loc_list_from_tree function.
References cfun, current_function_decl, dw_fde_struct::dw_fde_end, dw_fde_struct::dw_fde_second_begin, dw_fde_struct::dw_fde_second_end, dw_loc_list_1(), dw_loc_list_struct::dw_loc_next, dw_sra_loc_expr(), function::fde, var_loc_list_def::first, gen_llsym(), initialized, var_loc_node::label, var_loc_list_def::last_before_switch, var_loc_node::loc, new_loc_list(), var_loc_node::next, secname_for_decl(), and text_end_label.
Referenced by loc_list_from_tree().
|
static |
Helper function for dw_loc_list. Compute proper Dwarf location descriptor for VARLOC.
References add_loc_descr(), avoid_constant_pool_reference(), expansion_failed(), get_address_mode(), int_size_in_bytes(), loc_descriptor(), mem_loc_descriptor(), and new_loc_descr().
Referenced by dw_loc_list(), and dw_sra_loc_expr().
|
static |
Helper function for dw_loc_list. Compute proper Dwarf location descriptor for VAR_LOC_NOTE for variable DECL that has been optimized by SRA.
References decl_piece_bitsize(), decl_piece_varloc_ptr(), dw_loc_list_1(), dw_loc_descr_struct::dw_loc_next, dw_loc_descr_struct::dw_loc_oprnd1, host_integerp(), initialized, new_loc_descr_op_bit_piece(), offset, tree_low_cst(), dw_val_struct::v, and dw_val_struct::dw_val_struct_union::val_unsigned.
Referenced by dw_loc_list().
|
static |
Compare two location operands for exact equality.
References dw_vec_struct::array, dw_val_struct::dw_val_struct_union::dw_val_die_union::die, dw_val_class_addr, dw_val_class_const, dw_val_class_const_double, dw_val_class_data8, dw_val_class_decl_ref, dw_val_class_die_ref, dw_val_class_fde_ref, dw_val_class_file, dw_val_class_flag, dw_val_class_high_pc, dw_val_class_lbl_id, dw_val_class_lineptr, dw_val_class_loc, dw_val_class_loc_list, dw_val_class_macptr, dw_val_class_none, dw_val_class_offset, dw_val_class_range_list, dw_val_class_str, dw_val_class_unsigned_const, dw_val_class_vec, dw_val_class_vms_delta, dw_vec_struct::elt_size, double_int::high, dw_val_struct::dw_val_struct_union::dw_val_vms_delta_union::lbl1, dw_vec_struct::length, double_int::low, rtx_equal_p(), dw_val_struct::v, dw_val_struct::dw_val_struct_union::val_addr, dw_val_struct::val_class, dw_val_struct::dw_val_struct_union::val_data8, dw_val_struct::dw_val_struct_union::val_decl_ref, dw_val_struct::dw_val_struct_union::val_die_ref, dw_val_struct::dw_val_struct_union::val_double, dw_val_struct::dw_val_struct_union::val_fde_index, dw_val_struct::dw_val_struct_union::val_file, dw_val_struct::dw_val_struct_union::val_flag, dw_val_struct::dw_val_struct_union::val_lbl_id, dw_val_struct::dw_val_struct_union::val_loc, dw_val_struct::dw_val_struct_union::val_loc_list, dw_val_struct::dw_val_struct_union::val_str, dw_val_struct::dw_val_struct_union::val_unsigned, dw_val_struct::dw_val_struct_union::val_vec, and dw_val_struct::dw_val_struct_union::val_vms_delta.
Referenced by loc_descr_equal_p_1().
int dwarf2_build_local_stub | ( | ) |
htab_traverse callback function for optimize_external_refs, below. SLOT points to an external_ref, DATA is the CU we're processing. If we don't already have a local stub, and we have multiple refs, build a stub.
References add_AT_die_ref(), die_struct::comdat_type_p, die_struct::die_mark, die_struct::die_tag, external_ref::n_refs, new_die(), external_ref::stub, and external_ref::type.
Referenced by optimize_external_refs().
|
static |
|
static |
Return the DWARF2/3 pubname associated with a decl.
References lang_hooks::dwarf_name.
|
static |
Referenced by add_abstract_origin_attribute(), gen_decl_die(), and gen_inlined_subroutine_die().
|
static |
Generate the DWARF2 info for the "abstract" instance of a function which we may later generate inlined and/or out-of-line instances of.
References cached_dw_loc_list_table, call_arg_locations, call_site_count, comp_unit_die(), current_function_decl, decl_class_context(), decl_function_context(), decl_loc_table, DINFO_LEVEL_TERSE, dwarf2out_decl(), gen_type_die_for_member(), get_AT(), lookup_decl_die(), set_decl_abstract_flags(), and tail_call_site_count.
dw_fde_ref dwarf2out_alloc_current_fde | ( | void | ) |
Allocate CURRENT_FDE. Immediately initialize all we can, noting that this allocation may be done before pass_final.
References dw_fde_struct::all_throwers_are_sibcalls, cfun, current_function_decl, dw_fde_struct::decl, dw_fde_struct::drap_reg, function::fde, dw_fde_struct::fde_index, fde_vec, dw_fde_struct::funcdef_number, dw_fde_struct::nothrow, dw_fde_struct::uses_eh_lsda, dw_fde_struct::vdrap_reg, vec_safe_length(), and vec_safe_push().
Referenced by dwarf2out_begin_prologue(), and execute_dwarf2_frame().
|
static |
Called before compile () starts outputtting functions, variables and toplevel asms into assembly.
References asm_out_file, dwarf2out_do_cfi_asm(), and UI_DWARF2.
|
static |
|
static |
Output a marker (i.e. a label) for the beginning of the generated code for a lexical block.
References asm_out_file, current_function_section(), and switch_to_section().
|
static |
|
static |
We need to reset the locations at the beginning of each function. We can't do this in the end_function hook, because the declarations that use the locations won't have been output when that hook is called. Also compute have_multiple_function_sections here.
References asm_out_file, call_site_count, current_function_decl, dwarf2out_note_section_used(), function_section(), have_multiple_function_sections, set_cur_line_info_table(), switch_to_section(), tail_call_site_count, text_section, and unlikely_text_section().
void dwarf2out_begin_prologue | ( | unsigned int | line, |
const char * | file | ||
) |
Output a marker (i.e. a label) for the beginning of a function, before the prologue.
References asm_out_file, cfun, cold_text_section, current_function_decl, current_function_func_begin_label, dw_fde_struct::dw_fde_begin, dw_fde_struct::dw_fde_current_label, dwarf2out_alloc_current_fde(), dwarf2out_do_cfi_asm(), dwarf2out_do_cfi_startproc(), dwarf2out_do_frame(), dwarf2out_source_line(), function::fde, function_section(), get_personality_function(), dw_fde_struct::in_std_section, sorry(), switch_to_section(), text_section, and UI_SJLJ.
Referenced by final_start_function().
void dwarf2out_decl | ( | ) |
Write the debugging output for DECL.
References comp_unit_die(), decl_function_context(), DINFO_LEVEL_TERSE, gen_decl_die(), is_ada(), is_fortran(), and lookup_decl_die().
Referenced by dwarf2out_abstract_function(), dwarf2out_function_decl(), dwarf2out_global_decl(), dwarf2out_type_decl(), and force_decl_die().
|
static |
Called from debug_define in toplev.c. The `buffer' parameter contains the tail part of the directive line, i.e. the part which is past the initial whitespace, #, whitespace, directive-name, whitespace part.
References buffer, macinfo_struct::code, DINFO_LEVEL_VERBOSE, macinfo_struct::info, macinfo_struct::lineno, and vec_safe_push().
|
static |
Emit .cfi_startproc and .cfi_personality/.cfi_lsda if needed.
References asm_out_file, current_function_decl, dw2_force_const_mem(), get_personality_function(), and output_addr_const().
Referenced by dwarf2out_begin_prologue(), and dwarf2out_switch_text_section().
|
static |
|
static |
Output a marker (i.e. a label) for the end of the generated code for a lexical block.
References asm_out_file, current_function_section(), and switch_to_section().
void dwarf2out_end_epilogue | ( | unsigned int | line, |
const char * | file | ||
) |
Output a marker (i.e. a label) for the absolute end of the generated code for a function definition. This gets called *after* the epilogue code has been generated.
References asm_out_file, cached_next_real_insn, cfun, dw_fde_struct::dw_fde_end, dw_fde_struct::dw_fde_second_begin, dwarf2out_do_cfi_asm(), function::fde, and last_var_location_insn.
Referenced by final_end_function().
|
static |
|
static |
Hook called after emitting a function into assembly. This does something only for the very first function emitted.
References decl_loc_table, find_empty_loc_ranges_at_text_label(), and have_multiple_function_sections.
|
static |
|
static |
Record the end of a source file.
References macinfo_struct::code, comp_unit_die(), DINFO_LEVEL_VERBOSE, macinfo_struct::info, macinfo_struct::lineno, new_die(), and vec_safe_push().
|
static |
|
static |
Output stuff that dwarf requires at the end of every file, and generate the DWARF-2 debugging info.
References add_AT_addr(), add_AT_data8(), add_AT_lineptr(), add_AT_low_high_pc(), add_AT_macptr(), add_AT_pubnames(), add_child_die(), add_comp_dir_attribute(), add_linkage_attr(), add_location_or_const_value_attribute(), add_name_attribute(), add_ranges(), add_ranges_by_labels(), add_sibling_attributes(), add_top_level_skeleton_die_attrs(), addr_index_table, asm_out_file, break_out_comdat_types(), break_out_includes(), cold_text_section_used, comdat_type_list, comp_unit_die(), copy_decls_for_unworthy_types(), hash_table< Descriptor, Allocator >::create(), limbo_die_struct::created_for, dw_fde_struct::decl, deferred_asm_name, deferred_locations_list, limbo_die_struct::die, die_checksum(), die_struct::die_parent, DINFO_LEVEL_NORMAL, hash_table< Descriptor, Allocator >::dispose(), dw2_asm_output_data(), dw_attr_struct::dw_attr_val, dw_fde_struct::dw_fde_begin, dw_fde_struct::dw_fde_end, dw_fde_struct::dw_fde_second_begin, dw_fde_struct::dw_fde_second_end, fde_vec, file_table, file_table_relative_p(), find_AT_string(), hash_table< Descriptor, Allocator >::find_slot(), gen_compile_unit_die(), gen_producer_string(), gen_remaining_tmpl_value_param_die_attribute(), gen_scheduled_generic_parms_dies(), get_AT(), get_AT_ref(), get_context_die(), get_skeleton_type_unit(), have_multiple_function_sections, dw_fde_struct::in_std_section, index_addr_table_entry(), index_location_lists(), index_string(), is_cu_die(), limbo_die_list, move_linkage_attr(), move_marked_base_types(), comdat_type_struct::next, limbo_die_struct::next, optimize_location_lists(), output_abbrev_section(), output_addr_table(), output_aranges(), output_comdat_type_unit(), output_comp_unit(), output_indirect_strings(), output_line_info(), output_location_lists(), output_macinfo(), output_pubnames(), output_ranges(), output_skeleton_debug_sections(), prune_unused_types(), indirect_string_node::refcount, remap_debug_filename(), resolve_addr(), retry_incomplete_types(), comdat_type_struct::root_die, save_macinfo_strings(), scope_die_for(), dw_fde_struct::second_in_std_section, seen_error(), size_of_aranges(), switch_to_section(), targetm, text_section, text_section_used, unmark_all_dies(), dw_val_struct::v, and dw_val_struct::dw_val_struct_union::val_str.
void dwarf2out_frame_finish | ( | void | ) |
References output_call_frame_info(), targetm, and UI_DWARF2.
Referenced by compile_file().
|
static |
|
static |
Write the debugging output for DECL.
References block_map, call_arg_loc_last, call_arg_locations, call_site_count, decl_loc_table, dwarf2out_decl(), and tail_call_site_count.
|
static |
|
static |
Output debug information for global decl DECL. Called from toplev.c after compilation proper has finished.
References dwarf2out_decl().
|
static |
Referenced by gen_block_die().
|
static |
Returns nonzero if it is appropriate not to emit any debugging information for BLOCK, because it doesn't contain any instructions. Don't allow this for blocks with nested functions or local classes as we would end up with orphans, and in the presence of scheduling we may end up calling them anyway.
|
static |
Output debug information for imported module or decl DECL. NAME is non-NULL name in context if the decl has been renamed. CHILD is true if decl is one of the renamed decls as part of importing whole module.
References die_struct::die_child, die_struct::die_tag, DINFO_LEVEL_TERSE, DINFO_USAGE_DIR_USE, dwarf2out_imported_module_or_decl_1(), get_context_die(), and should_emit_struct_debug().
|
static |
Output debug information for imported module or decl DECL. NAME is non-NULL name in the lexical block if the decl has been renamed. LEXICAL_BLOCK is the lexical block (which TREE_CODE is a BLOCK) that DECL belongs to. LEXICAL_BLOCK_DIE is the DIE of LEXICAL_BLOCK.
References add_AT_die_ref(), add_AT_file(), add_AT_string(), add_AT_unsigned(), DINFO_USAGE_DIR_USE, expand_location(), force_decl_die(), force_type_die(), gen_type_die_for_member(), gen_typedef_die(), get_context_die(), input_location, lookup_decl_die(), lookup_filename(), lookup_type_die(), new_die(), and should_emit_struct_debug().
Referenced by dwarf2out_imported_module_or_decl(), and process_scope_var().
|
static |
|
static |
Set up for Dwarf output at the start of compilation.
References asm_out_file, cached_dw_loc_list_table_eq(), cached_dw_loc_list_table_hash(), decl_die_table, decl_die_table_eq(), decl_die_table_hash(), decl_loc_table, decl_loc_table_eq(), decl_loc_table_hash(), DINFO_LEVEL_VERBOSE, dw_line_info_table_struct::end_label, file_table, file_table_eq(), file_table_hash(), get_section(), new_line_info_table(), switch_to_section(), text_end_label, text_section, and vec_alloc().
|
static |
Note that the current function section is being used for code.
References cold_text_section_used, current_function_section(), text_section, and text_section_used.
Referenced by dwarf2out_begin_function(), and dwarf2out_switch_text_section().
void dwarf2out_set_demangle_name_func | ( | const char *(*)(const char *) | func | ) |
References demangle_name_func.
|
static |
Replace DW_AT_name for the decl with name.
References add_name_attribute(), dw_attr_struct::dw_attr_val, dwarf2_name(), find_AT_string(), get_AT(), dw_val_struct::v, and dw_val_struct::dw_val_struct_union::val_str.
|
static |
@verbatim Output Dwarf2 format symbol table information from GCC.
Copyright (C) 1992-2013 Free Software Foundation, Inc. Contributed by Gary Funck (gary@). Derived from DWARF 1 implementation of Ron Guilmette ( intr epid. comrfg@m). Extensively modified by Jason Merrill ( onke ys.co mjason). @cyg nus.c om
This file is part of GCC.
GCC is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 3, or (at your option) any later version.
GCC is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with GCC; see the file COPYING3. If not see http://www.gnu.org/licenses/.
TODO: Emit .debug_line header even when there are no functions, since the file numbers are used by .debug_info. Alternately, leave out locations for types and decls. Avoid talking about ctors and op= for PODs. Factor out common prologue sequences into multiple CIEs.
The first part of this file deals with the DWARF 2 frame unwind information, which is also used by the GCC efficient exception handling mechanism. The second part, controlled only by an #ifdef DWARF2_DEBUGGING_INFO, deals with the other DWARF 2 debugging information.
DWARF2 Abbreviation Glossary: CFA = Canonical Frame Address a fixed address on the stack which identifies a call frame. We define it to be the value of SP just before the call insn. The CFA register and offset, which may change during the course of the function, are used to calculate its value at runtime. CFI = Call Frame Instruction an instruction for the DWARF2 abstract machine CIE = Common Information Entry information describing information common to one or more FDEs DIE = Debugging Information Entry FDE = Frame Description Entry information describing the stack call frame, in particular, how to restore registers DW_CFA_... = DWARF2 CFA call frame instruction DW_TAG_... = DWARF2 DIE tag
Output a label to mark the beginning of a source code line entry and record information relating to this source line, in 'line_info_table' for later output of the .debug_line section.
??? The discriminator parameter ought to be unsigned.
References asm_out_file, cur_line_info_table, current_function_section(), DINFO_LEVEL_NORMAL, dw_line_info_table_struct::discrim_num, discriminator, dw_line_info_table_struct::file_num, fprint_ul(), dw_line_info_table_struct::in_use, dw_line_info_table_struct::is_stmt, LI_negate_stmt, LI_set_address, LI_set_discriminator, LI_set_file, LI_set_line, line_info_label_num, dw_line_info_table_struct::line_num, lookup_filename(), maybe_emit_file(), push_dw_line_info_entry(), switch_to_section(), table, and targetm.
Referenced by dwarf2out_begin_prologue().
|
static |
|
static |
Record the beginning of a new source file.
References add_AT_string(), macinfo_struct::code, comp_unit_die(), DINFO_LEVEL_VERBOSE, macinfo_struct::info, macinfo_struct::lineno, new_die(), remap_debug_filename(), and vec_safe_push().
void dwarf2out_switch_text_section | ( | void | ) |
References asm_out_file, cfun, cold_text_section, current_function_section(), dw_fde_struct::dw_fde_end, dw_fde_struct::dw_fde_second_begin, dw_fde_struct::dw_fde_second_end, dwarf2out_do_cfi_asm(), dwarf2out_do_cfi_startproc(), dwarf2out_note_section_used(), function::fde, have_multiple_function_sections, in_cold_section_p, dw_fde_struct::second_in_std_section, set_cur_line_info_table(), switch_to_section(), text_section, and var_location_switch_text_section().
Referenced by final_scan_insn().
|
static |
|
static |
Output debug information for type decl DECL. Called from toplev.c and from language front ends (to record built-in types).
References dwarf2out_decl().
|
static |
Called from debug_undef in toplev.c. The `buffer' parameter contains the tail part of the directive line, i.e. the part which is past the initial whitespace, #, whitespace, directive-name, whitespace part.
References buffer, macinfo_struct::code, DINFO_LEVEL_VERBOSE, macinfo_struct::info, macinfo_struct::lineno, and vec_safe_push().
|
static |
|
static |
Called by the final INSN scan whenever we see a var location. We use it to drop labels in the right places, and throw the location in our lookup table.
References add_var_loc_to_decl(), asm_noperands(), asm_out_file, call_arg_loc_node::block, cached_next_real_insn, call_arg_loc_last, call_arg_loc_node::call_arg_loc_note, call_arg_locations, call_site_count, get_attr_min_length(), get_call_rtx_from(), get_last_insn(), have_multiple_function_sections, in_cold_section_p, insn_scope(), var_loc_node::label, call_arg_loc_node::label, last_var_location_insn, loclabel_num, call_arg_loc_node::next, next_real_insn(), prev_real_insn(), previous_insn(), call_arg_loc_node::symbol_ref, call_arg_loc_node::tail_call_p, and tail_call_site_count.
void dwarf2out_vms_begin_epilogue | ( | unsigned int | line, |
const char * | file | ||
) |
Output a marker (i.e. a label) for the beginning of the generated code for a function epilogue. This gets called *before* the prologue code has been generated.
References asm_out_file, cfun, dw_fde_struct::dw_fde_vms_begin_epilogue, and function::fde.
void dwarf2out_vms_debug_main_pointer | ( | ) |
Output the debug main pointer die for VMS
References add_AT_lbl_id(), add_name_attribute(), comp_unit_die(), die_struct::die_child, die_struct::die_parent, die_struct::die_sib, and die_struct::die_tag.
void dwarf2out_vms_end_prologue | ( | unsigned int | line, |
const char * | file | ||
) |
Output a marker (i.e. a label) for the end of the generated code for a function prologue. This gets called *after* the prologue code has been generated.
References asm_out_file, cfun, dw_fde_struct::dw_fde_vms_end_prologue, and function::fde.
|
static |
|
static |
Convert a DWARF attribute code into its string name.
|
static |
Referenced by output_value_format().
|
static |
Convert a DWARF value form code into its string name.
|
static |
Convert a DWARF stack opcode into its string name.
Referenced by output_loc_sequence().
|
static |
Referenced by output_die(), output_die_abbrevs(), and print_die().
|
static |
Convert a DIE tag into its string name.
|
static |
|
static |
Equate a DIE to a particular declaration.
References decl_die_table, and die_struct::decl_id.
|
static |
|
inlinestatic |
Equate a DIE to a given type specifier.
|
static |
Output debug info about reason why we failed to expand expression as dwarf expression.
References dump_file, dump_flags, print_generic_expr(), and print_rtl().
Referenced by add_loc_list(), const_ok_for_output_1(), cst_pool_loc_descr(), dw_loc_list_1(), loc_descriptor_from_tree(), loc_list_for_address_of_addr_expr_of_indirect_ref(), loc_list_from_tree(), and mem_loc_descriptor().
|
static |
Referenced by output_die(), and output_loc_operands().
|
static |
Reads integers from dw_vec_const array. Inverse of insert_int.
|
static |
Return true if frame description entry FDE is needed for EH.
References dw_fde_struct::all_throwers_are_sibcalls, dw_fde_struct::decl, dw_fde_struct::nothrow, and dw_fde_struct::uses_eh_lsda.
Referenced by output_call_frame_info().
|
static |
Referenced by add_bit_offset_attribute(), and add_data_member_location_attribute().
|
static |
Given a pointer to a FIELD_DECL, compute and return the byte offset of the lowest addressed byte of the "containing object" for the given FIELD_DECL, or return 0 if we are unable to determine what that offset is, either because the argument turns out to be a pointer to an ERROR_MARK node, or because the offset is actually variable. (We can't handle the latter case just yet).
References bit_position(), double_int::div(), double_int_type_size_in_bits(), field_type(), double_int::from_uhwi(), round_up_to_align(), simple_decl_align_in_bits(), simple_type_align_in_bits(), double_int::to_shwi(), tree_to_double_int(), type(), and double_int::ugt().
|
static |
Referenced by add_byte_size_attribute(), field_byte_offset(), record_or_union_type_has_array_p(), and write_field_root().
|
inlinestatic |
Given a pointer to what is assumed to be a FIELD_DECL node, return a pointer to the declared type for the relevant field variable, or return `integer_type_node' if the given node turns out to be an ERROR_MARK node.
References type().
|
static |
Referenced by output_file_names().
|
static |
Callback function for file_info comparison. We sort by looking at the directories in the path.
References file_info::fname, and file_info::path.
|
static |
Traversal function for the hash table.
References dwarf_file_data::emitted_number, file_info::file_idx, dwarf_file_data::filename, file_name_acquire_data::files, file_info::fname, g, file_info::length, file_name_acquire_data::max_files, file_info::path, strlen(), and file_name_acquire_data::used_files.
Referenced by output_file_names().
|
static |
Hash table routines for file_hash.
References dwarf_file_data::filename.
Referenced by dwarf2out_init().
|
static |
References dwarf_file_data::filename.
Referenced by dwarf2out_init().
|
static |
Set the parameter to true if there are any relative pathnames in the file table.
References dwarf_file_data::filename.
Referenced by dwarf2out_finish().
|
staticread |
Add STR to the indirect string hash table.
References debug_str_do_hash(), debug_str_eq(), and find_AT_string_in_table().
Referenced by add_AT_string(), dwarf2out_finish(), dwarf2out_set_name(), output_macinfo_op(), and save_macinfo_strings().
|
staticread |
Add STR to the given string hash table.
References indirect_string_node::refcount, and indirect_string_node::str.
Referenced by add_skeleton_AT_string(), and find_AT_string().
|
static |
Helper function of dwarf2out_end_function, called only after emitting the very first function into assembly. Check if some .debug_loc range might end with a .LVL* label that could be equal to .Ltext0. In that case we must force using absolute addresses in .debug_loc ranges, because this range could be .LVLN-.Ltext0 .. .LVLM-.Ltext0 for .LVLN == .LVLM == .Ltext0, thus 0 .. 0, which is a .debug_loc list terminator. Set have_multiple_function_sections to true in that case and terminate htab traversal.
References var_loc_list_def::first, first_loclabel_num_not_at_text_label, have_multiple_function_sections, var_loc_node::label, and var_loc_node::next.
Referenced by dwarf2out_end_function().
|
static |
Find out whether a string should be output inline in DIE or out-of-line in .debug_str section.
References indirect_string_node::form, len, indirect_string_node::refcount, set_indirect_string(), indirect_string_node::str, and strlen().
Referenced by add_skeleton_AT_string(), AT_string_form(), index_string(), and output_indirect_string().
|
static |
|
static |
Returns the DIE for decl. A DIE will always be returned.
References comp_unit_die(), current_function_decl, dwarf2out_decl(), gen_decl_die(), gen_subprogram_die(), get_context_die(), and lookup_decl_die().
|
static |
Referenced by dwarf2out_imported_module_or_decl_1(), and get_context_die().
|
static |
Returns the DIE for TYPE, that must not be a base type. A DIE is always returned.
References get_context_die(), lookup_type_die(), and modified_type_die().
|
static |
Check whether decl is a Fortran COMMON symbol. If not, NULL_TREE is returned. If so, the decl for the COMMON block is returned, and the value is the offset into the common block for the symbol.
References get_inner_reference(), host_integerp(), is_fortran(), offset, and tree_low_cst().
Referenced by gen_variable_die().
|
static |
Referenced by gen_type_die_with_usage().
|
static |
These routines generate the internal representation of the DIE's for the compilation unit. Debugging information is collected by walking the declaration trees passed in from dwarf2out_decl().
References add_AT_flag(), add_AT_location_description(), add_AT_unsigned(), add_bound_info(), add_gnat_descriptive_type_attribute(), add_name_attribute(), add_pubtype(), add_subscript_info(), add_type_attribute(), equate_type_number_to_die(), get_AT(), int_size_in_bytes(), is_ada(), is_fortran(), loc_list_from_tree(), new_die(), scope_die_for(), and type_tag().
|
static |
Referenced by decls_for_scope(), and gen_block_die().
|
static |
Generate a DW_TAG_lexical_block DIE followed by DIEs to represent all of the things which are local to the given block.
References decls_for_scope(), DINFO_LEVEL_TERSE, dwarf2out_ignore_block(), gen_block_die(), gen_inlined_subroutine_die(), gen_lexical_block_die(), and inlined_function_outer_scope_p().
|
static |
Generate a DW_TAG_GNU_call_site DIE in function DECL under SUBR_DIE for CA_LOC call arg loc node.
References add_AT_addr(), add_AT_die_ref(), add_AT_flag(), add_AT_lbl_id(), call_arg_loc_node::block, block_map, call_arg_loc_node::label, lookup_decl_die(), new_die(), call_arg_loc_node::symbol_ref, and call_arg_loc_node::tail_call_p.
Referenced by gen_subprogram_die().
|
static |
Referenced by comp_unit_die(), dwarf2out_finish(), and push_new_compile_unit().
|
static |
Generate the DIE for the compilation unit.
References add_AT_string(), add_AT_unsigned(), add_comp_dir_attribute(), add_name_attribute(), all_translation_units, lang_hooks::name, and new_die().
|
static |
Referenced by gen_decl_die().
|
static |
Generate a DIE to represent a named constant.
References add_AT_flag(), add_name_and_src_coords_attributes(), add_type_attribute(), new_die(), and tree_add_const_value_attribute_for_decl().
|
static |
|
static |
Generate Dwarf debug information for a decl described by DECL. The return value is currently only meaningful for PARM_DECLs, for all other decls it returns NULL.
References cgraph_function_possibly_inlined_p(), class_or_namespace_scope_p(), current_function_decl, decl_by_reference_p(), decl_class_context(), decl_ultimate_origin(), declare_in_namespace(), DINFO_LEVEL_NORMAL, DINFO_LEVEL_TERSE, dwarf2out_abstract_function(), gen_const_die(), gen_field_die(), gen_formal_parameter_die(), gen_label_die(), gen_namespace_die(), gen_subprogram_die(), gen_type_die(), gen_type_die_for_member(), gen_typedef_die(), gen_variable_die(), is_ada(), is_fortran(), is_redundant_typedef(), member_declared_type(), and set_decl_origin_self().
|
static |
This routine generates DIE for array with hidden descriptor, details are filled into *info by a langhook.
References add_AT_unsigned(), add_descr_info_field(), add_name_attribute(), add_pubtype(), add_type_attribute(), array_descr_info::allocated, array_descr_info::associated, array_descr_info::base_decl, array_descr_info::data_location, array_descr_info::dimen, array_descr_info::element_type, equate_type_number_to_die(), gen_type_die(), get_AT(), host_integerp(), is_fortran(), array_descr_info::array_descr_dimen::lower_bound, lower_bound_default(), array_descr_info::ndimensions, new_die(), scope_die_for(), array_descr_info::array_descr_dimen::stride, tree_low_cst(), type_tag(), and array_descr_info::array_descr_dimen::upper_bound.
Referenced by gen_type_die_with_usage().
|
static |
|
static |
|
static |
Referenced by gen_tagged_type_die().
|
static |
Generate a DIE to represent an enumeration type. Note that these DIEs include all of the information about the enumeration values also. Each enumerated type name/value is listed as a child of the enumerated type DIE.
References add_accessibility_attribute(), add_AT_double(), add_AT_flag(), add_AT_int(), add_byte_size_attribute(), add_child_die(), add_gnat_descriptive_type_attribute(), add_name_attribute(), add_pubtype(), add_src_coords_attributes(), die_struct::die_parent, equate_type_number_to_die(), HOST_BITS_PER_WIDE_INT, host_integerp(), lookup_type_die(), new_die(), remove_AT(), scope_die_for(), simple_type_size_in_bits(), and type_tag().
|
static |
Referenced by gen_decl_die(), and gen_type_die_for_member().
|
static |
Generate a DIE for a field in a record, or structure.
References add_accessibility_attribute(), add_AT_flag(), add_bit_offset_attribute(), add_bit_size_attribute(), add_byte_size_attribute(), add_data_member_location_attribute(), add_name_and_src_coords_attributes(), add_type_attribute(), equate_decl_number_to_die(), member_declared_type(), and new_die().
|
static |
Generate a DIE to represent either a real live formal parameter decl or to represent just the type of some formal parameter position in some function type. Note that this routine is a bit unusual because its argument may be a ..._DECL node (i.e. either a PARM_DECL or perhaps a VAR_DECL which represents an inlining of some PARM_DECL) or else some sort of a ..._TYPE node. If it's the former then this function is being called to output a DIE to represent a formal parameter object (or some inlining thereof). If it's the latter, then this function is only being called to output a DW_TAG_formal_parameter DIE to stand as a placeholder for some formal argument type of some subprogram type. If EMIT_NAME_P is true, name and source coordinate attributes are emitted.
References add_abstract_origin_attribute(), add_AT_flag(), add_location_or_const_value_attribute(), add_name_and_src_coords_attributes(), add_type_attribute(), decl_by_reference_p(), decl_function_context(), decl_ultimate_origin(), equate_decl_number_to_die(), new_die(), tcc_declaration, tcc_type, and variably_modified_type_p().
Referenced by gen_decl_die(), gen_formal_parameter_pack_die(), and gen_formal_types_die().
|
static |
Generate and return a DW_TAG_GNU_formal_parameter_pack. Also generate children DW_TAG_formal_parameter DIEs representing the arguments of the parameter pack. PARM_PACK must be a function parameter pack. PACK_ARG is the first argument of the parameter pack. Its TREE_CHAIN must point to the subsequent arguments of the function PACK_ARG belongs to. SUBR_DIE is the DIE of the function PACK_ARG belongs to. If NEXT_ARG is non NULL, *NEXT_ARG is set to the function argument following the last one for which a DIE was generated.
References add_src_coords_attributes(), lang_hooks::decls, lang_hooks::function_parameter_pack_p, lang_hooks_for_decls::function_parm_expanded_from_pack_p, gen_formal_parameter_die(), and new_die().
Referenced by gen_subprogram_die().
|
static |
Referenced by gen_subprogram_die(), and gen_subroutine_type_die().
|
static |
Generate a list of nameless DW_TAG_formal_parameter DIEs (and perhaps a DW_TAG_unspecified_parameters DIE) to represent the types of the formal parameters as specified in some function type specification (except for those which appear as part of a function *definition*).
References add_AT_die_ref(), add_AT_flag(), gen_formal_parameter_die(), gen_type_die(), and gen_unspecified_parameters_die().
|
static |
Referenced by gen_scheduled_generic_parms_dies(), and gen_subprogram_die().
|
static |
Generate DIEs for the generic parameters of T. T must be either a generic type or a generic function. See http://gcc.gnu.org/wiki/TemplateParmsDwarf for more.
References add_AT_flag(), generic_parameter_die(), lang_hooks_for_types::get_argument_pack_elems, lang_hooks::get_innermost_generic_args, lang_hooks::get_innermost_generic_parms, int_cst_value(), lookup_decl_die(), lookup_type_die(), template_parameter_pack_die(), and lang_hooks::types.
|
static |
Referenced by gen_member_die().
|
static |
Generate the DIE for a base class.
References add_AT_unsigned(), add_data_member_location_attribute(), add_type_attribute(), die_struct::die_tag, and new_die().
|
static |
Referenced by gen_block_die().
|
static |
Generate a DIE for an inlined subprogram.
References add_abstract_origin_attribute(), add_call_src_coords_attributes(), add_high_low_attributes(), block_map, block_ultimate_origin(), call_arg_locations, decls_for_scope(), dwarf2out_abstract_function(), and new_die().
|
static |
Referenced by assign_symbol_names(), and gen_llsym().
|
static |
|
static |
Referenced by gen_decl_die().
|
static |
Generate a DIE to represent a label identifier.
References add_abstract_origin_attribute(), add_AT_lbl_id(), add_name_and_src_coords_attributes(), decl_ultimate_origin(), equate_decl_number_to_die(), and new_die().
|
static |
Referenced by gen_block_die().
|
static |
Generate a DIE for a lexical block.
References add_high_low_attributes(), block_map, call_arg_locations, decls_for_scope(), and new_die().
|
inlinestatic |
Generate a new internal symbol for this location list node, if it hasn't got one yet.
References gen_internal_sym(), and dw_loc_list_struct::ll_symbol.
Referenced by convert_cfa_to_fb_loc_list(), and dw_loc_list().
|
static |
Referenced by gen_struct_or_union_type_die().
|
static |
Generate a DIE for a class member.
References gen_decl_die(), gen_inheritance_die(), lookup_decl_die(), and splice_child_die().
|
static |
Referenced by gen_decl_die().
|
static |
Generate a DIE for a namespace or namespace alias.
References add_AT_die_ref(), add_AT_flag(), add_name_and_src_coords_attributes(), add_name_attribute(), add_pubname_string(), comp_unit_die(), die_struct::die_tag, dwarf2_name(), lang_hooks::dwarf_name, equate_decl_number_to_die(), force_decl_die(), is_fortran(), new_die(), setup_namespace_context(), and want_pubnames().
|
static |
Don't generate either pointer_type DIEs or reference_type DIEs here. Use modified_type_die instead. We keep this code here just in case these types of DIEs may be needed to represent certain things in other languages (e.g. Pascal) someday.
References add_AT_unsigned(), add_type_attribute(), equate_type_number_to_die(), new_die(), and scope_die_for().
|
static |
Return a heap allocated producer string including command line options if -grecord-gcc-switches.
References cl_options, len, memcpy(), lang_hooks::name, save_decoded_options, save_decoded_options_count, strlen(), switches, version_string, and vNULL.
Referenced by dwarf2out_finish().
|
static |
Referenced by gen_type_die_with_usage().
|
static |
Generate a DIE for a pointer to a member type.
References add_AT_die_ref(), add_type_attribute(), equate_type_number_to_die(), lookup_type_die(), new_die(), and scope_die_for().
|
static |
Don't generate either pointer_type DIEs or reference_type DIEs here. Use modified_type_die instead. We keep this code here just in case these types of DIEs may be needed to represent certain things in other languages (e.g. Pascal) someday.
References add_AT_unsigned(), add_type_attribute(), equate_type_number_to_die(), new_die(), and scope_die_for().
|
static |
Add a DW_AT_const_value attribute to DIEs that were scheduled by append_entry_to_tmpl_value_parm_die_table. This function must be called after function DIEs have been generated.
References die_arg_entry_struct::arg, die_arg_entry_struct::die, and tree_add_const_value_attribute().
Referenced by dwarf2out_finish().
|
static |
Generate generic parameters DIEs for instances of generic types that have been previously scheduled by schedule_generic_params_dies_gen. This function must be called after all the types of the CU have been laid out.
References gen_generic_params_dies().
Referenced by dwarf2out_finish().
|
static |
Generate a DIE for a structure or union type. If TYPE_DECL_SUPPRESS_DEBUG is set, we pretend that the type was never defined, so we only get the member DIEs needed by later specification DIEs.
References add_accessibility_attribute(), add_AT_die_ref(), add_AT_flag(), add_AT_specification(), add_byte_size_attribute(), add_child_die(), add_gnat_descriptive_type_attribute(), add_name_attribute(), add_pubtype(), add_src_coords_attributes(), decl_function_context(), die_struct::die_parent, die_struct::die_tag, DINFO_LEVEL_TERSE, equate_type_number_to_die(), gen_member_die(), gen_type_die(), get_AT(), is_cu_die(), lookup_type_die(), new_die(), pop_decl_scope(), push_decl_scope(), record_type_tag(), remove_AT(), schedule_generic_params_dies_gen(), scope_die_for(), should_emit_struct_debug(), type_tag(), and vec_safe_push().
Referenced by gen_tagged_type_die().
|
static |
Referenced by force_decl_die(), gen_decl_die(), and gen_type_die_for_member().
|
static |
Generate a DIE to represent a declared function (either file-scope or block-local).
References add_abstract_origin_attribute(), add_accessibility_attribute(), add_AT_die_ref(), add_AT_file(), add_AT_flag(), add_AT_loc(), add_AT_loc_list(), add_AT_location_description(), add_AT_low_high_pc(), add_AT_specification(), add_AT_unsigned(), add_AT_vms_delta(), add_calling_convention_attribute(), add_child_die(), add_linkage_name(), add_name_and_src_coords_attributes(), add_name_attribute(), add_prototyped_attribute(), add_pubname(), add_pubname_string(), add_pure_or_virtual_attribute(), add_ranges(), add_ranges_by_labels(), add_src_coords_attributes(), add_type_attribute(), call_arg_loc_last, call_arg_loc_node::call_arg_loc_note, call_arg_locations, call_site_count, cgraph_function_possibly_inlined_p(), class_or_namespace_scope_p(), compute_frame_pointer_to_fb_displacement(), convert_cfa_to_fb_loc_list(), current_function_decl, decl_name(), decl_ultimate_origin(), lang_hooks::decls, decls_for_scope(), die_struct::die_parent, DINFO_LEVEL_TERSE, dw_fde_struct::dw_fde_begin, dw_fde_struct::dw_fde_end, dw_fde_struct::dw_fde_second_begin, dw_fde_struct::dw_fde_second_end, dw_fde_struct::dw_fde_vms_begin_epilogue, dw_fde_struct::dw_fde_vms_end_prologue, dw_loc_list_struct::dw_loc_next, dwarf2_name(), equate_decl_number_to_die(), expand_location(), dw_loc_list_struct::expr, force_decl_die(), lang_hooks_for_decls::function_decl_explicit_p, lang_hooks::function_parameter_pack_p, gen_call_site_die(), gen_decl_die(), gen_formal_parameter_pack_die(), gen_formal_types_die(), gen_generic_params_dies(), gen_unspecified_parameters_die(), get_address_mode(), get_AT(), get_AT_file(), get_AT_flag(), get_AT_unsigned(), lang_hooks_for_decls::get_generic_function_decl, is_cu_die(), loc_list_from_tree(), local_scope_p(), lookup_attribute(), lookup_decl_die(), lookup_filename(), mem_loc_descriptor(), new_die(), new_loc_descr(), call_arg_loc_node::next, pc_rtx, premark_used_types(), prototype_p(), reg_loc_descriptor(), remove_AT(), remove_child_TAG(), stdarg_p(), call_arg_loc_node::symbol_ref, call_arg_loc_node::tail_call_p, tail_call_site_count, targetm, UI_DWARF2, VAR_INIT_STATUS_INITIALIZED, and want_pubnames().
|
static |
Referenced by gen_type_die_with_usage().
|
static |
Generate a DIE for a subroutine _type_.
References add_prototyped_attribute(), add_pubtype(), add_type_attribute(), equate_type_number_to_die(), gen_formal_types_die(), get_AT(), new_die(), and scope_die_for().
|
static |
Generate a DIE for a struct, class, enum or union type.
References declare_in_namespace(), gen_enumeration_type_die(), gen_struct_or_union_type_die(), gen_type_die_with_usage(), is_declaration_die(), is_tagged_type(), lookup_decl_die(), lookup_type_die(), pop_decl_scope(), and push_decl_scope().
Referenced by gen_type_die_with_usage(), and gen_typedef_die().
|
static |
|
static |
References DINFO_USAGE_DIR_USE, and gen_type_die_with_usage().
|
static |
Referenced by dwarf2out_abstract_function(), dwarf2out_imported_module_or_decl_1(), and gen_decl_die().
|
static |
We want to generate the DIE for TYPE so that we can generate the die for MEMBER, which has been defined; we will need to refer back to the member declaration nested within TYPE. If we're trying to generate minimal debug info for TYPE, processing TYPE won't do the trick; we need to attach the member declaration by hand.
References decl_ultimate_origin(), gen_field_die(), gen_subprogram_die(), gen_type_die(), gen_variable_die(), lookup_decl_die(), lookup_type_die_strip_naming_typedef(), member_declared_type(), pop_decl_scope(), and push_decl_scope().
|
static |
Generate a type description DIE.
References add_name_attribute(), comp_unit_die(), DINFO_USAGE_DIR_USE, DINFO_USAGE_IND_USE, equate_type_number_to_die(), gen_array_type_die(), gen_decl_die(), gen_descr_array_type_die(), gen_ptr_to_mbr_type_die(), gen_subroutine_type_die(), gen_tagged_type_die(), lang_hooks_for_types::get_array_descr_info, get_context_die(), is_naming_typedef_decl(), is_redundant_typedef(), lookup_type_die(), new_die(), scope_die_for(), type_main_variant(), typedef_variant_p(), and lang_hooks::types.
Referenced by gen_tagged_type_die(), and gen_type_die().
|
static |
Referenced by dwarf2out_imported_module_or_decl_1(), and gen_decl_die().
|
static |
Generate a DIE for a type definition.
References add_abstract_origin_attribute(), add_accessibility_attribute(), add_linkage_attr(), add_name_and_src_coords_attributes(), add_pubtype(), add_type_attribute(), decl_ultimate_origin(), DINFO_USAGE_DIR_USE, equate_decl_number_to_die(), equate_type_number_to_die(), gen_tagged_type_die(), get_AT(), is_naming_typedef_decl(), lookup_type_die(), new_die(), and type().
|
static |
Referenced by gen_formal_types_die(), and gen_subprogram_die().
|
static |
Generate a special type of DIE used as a stand-in for a trailing ellipsis at the end of an (ANSI prototyped) formal parameters list.
References new_die().
|
static |
Referenced by gen_decl_die(), and gen_type_die_for_member().
|
static |
Generate a DIE to represent a declared data object. Either DECL or ORIGIN must be non-null.
References add_abstract_origin_attribute(), add_accessibility_attribute(), add_AT_file(), add_AT_flag(), add_AT_location_description(), add_AT_specification(), add_AT_unsigned(), add_linkage_name(), add_location_or_const_value_attribute(), add_name_and_src_coords_attributes(), add_pubname(), add_pubname_string(), add_type_attribute(), class_or_namespace_scope_p(), class_scope_p(), common_block_die_table, common_block_die_table_eq(), common_block_die_table_hash(), decl_by_reference_p(), decl_function_context(), die_struct::decl_id, decl_ultimate_origin(), defer_location(), die_struct::die_parent, die_struct::die_tag, dw_loc_descr_struct::dw_loc_next, dw_loc_descr_struct::dw_loc_oprnd1, equate_decl_number_to_die(), expand_location(), dw_loc_list_struct::expr, fortran_common(), get_AT(), get_AT_file(), get_AT_flag(), get_AT_unsigned(), loc_list_from_tree(), loc_list_plus_const(), local_scope_p(), lookup_decl_die(), lookup_filename(), new_die(), plus_constant(), remove_AT(), single_element_loc_list_p(), tree_add_const_value_attribute_for_decl(), dw_val_struct::v, dw_val_struct::dw_val_struct_union::val_addr, variably_modified_type_p(), and want_pubnames().
|
static |
Referenced by remove_child_or_replace_with_skeleton().
|
static |
Wrapper function for generate_skeleton_bottom_up.
References clone_as_declaration(), die_struct::die_parent, generate_skeleton_bottom_up(), is_template_instantiation(), is_type_die(), skeleton_chain_struct::new_die, skeleton_chain_struct::old_die, and skeleton_chain_struct::parent.
|
static |
Referenced by generate_skeleton_ancestor_tree(), and generate_skeleton_bottom_up().
|
static |
Generate the skeleton ancestor tree for the given NODE, then clone the DIE and add the clone into the tree.
References add_child_die(), clone_as_declaration(), generate_skeleton_ancestor_tree(), skeleton_chain_struct::new_die, skeleton_chain_struct::old_die, and skeleton_chain_struct::parent.
|
static |
Referenced by generate_skeleton(), and generate_skeleton_bottom_up().
|
static |
Generate a skeleton tree of DIEs containing any declarations that are found in the original tree. We traverse the tree looking for declaration DIEs, and construct the skeleton from the bottom up whenever we find one.
References add_child_die(), clone_die(), die_struct::die_child, die_struct::die_sib, first, generate_skeleton_ancestor_tree(), generate_skeleton_bottom_up(), is_declaration_die(), is_template_instantiation(), move_all_children(), skeleton_chain_struct::new_die, skeleton_chain_struct::old_die, skeleton_chain_struct::parent, remove_child_with_prev(), and replace_child().
|
static |
Referenced by break_out_comdat_types().
|
static |
Generate the type signature for DIE. This is computed by generating an MD5 checksum over the DIE's tag, its relevant attributes, and its children. Attributes that are references to other DIEs are processed by recursion, using the MARK field to prevent infinite recursion. If the DIE is nested inside a namespace or another type, we also need to include that context in the signature. The lower 64 bits of the resulting MD5 checksum comprise the signature.
References add_AT_data8(), checksum_die_context(), die_struct::comdat_type_p, die_checksum_ordered(), die_struct::die_id, die_struct::die_mark, die_odr_checksum(), die_struct::die_tag, die_struct::die_symbol_or_type_node::die_type_node, get_AT_ref(), get_AT_string(), get_die_parent(), is_cxx(), memcpy(), comdat_type_struct::root_die, comdat_type_struct::signature, comdat_type_struct::type_die, and unmark_all_dies().
|
static |
Create and return a DIE for PARM which should be the representation of a generic type parameter. For instance, in the C++ front end, PARM would be a template parameter. ARG is the argument to PARM. EMIT_NAME_P if tree, the DIE will have DW_AT_name attribute set to the name of the PARM. PARENT_DIE is the parent DIE which the new created DIE should be added to, as a child node.
References add_AT_string(), add_type_attribute(), append_entry_to_tmpl_value_parm_die_table(), lang_hooks::decls, dwarf2_name(), lang_hooks_for_decls::generic_generic_parameter_decl_p, and new_die().
Referenced by gen_generic_params_dies(), and template_parameter_pack_die().
|
static |
Referenced by schedule_generic_params_dies_gen().
|
static |
Return TRUE if T is an instance of generic type, FALSE otherwise.
References lang_hooks::get_innermost_generic_parms.
|
static |
Referenced by add_high_low_attributes(), attr_checksum_ordered(), die_checksum_ordered(), dwarf2out_abstract_function(), dwarf2out_finish(), dwarf2out_set_name(), gen_array_type_die(), gen_descr_array_type_die(), gen_struct_or_union_type_die(), gen_subprogram_die(), gen_subroutine_type_die(), gen_typedef_die(), gen_variable_die(), get_AT(), get_AT_file(), get_AT_flag(), get_AT_hi_pc(), get_AT_low_pc(), get_AT_ref(), get_AT_string(), get_AT_unsigned(), optimize_location_into_implicit_ptr(), optimize_one_addr_into_implicit_ptr(), should_move_die_to_comdat(), and tree_add_const_value_attribute_for_decl().
|
static |
Get the attribute of type attr_kind.
References AT_ref(), die_struct::die_attr, dw_attr_struct::dw_attr, and get_AT().
|
staticread |
References AT_file(), and get_AT().
Referenced by gen_subprogram_die(), and gen_variable_die().
|
static |
|
inlinestatic |
|
static |
|
inlinestatic |
|
static |
Referenced by output_die().
|
inlinestatic |
|
inlinestatic |
Referenced by attr_checksum_ordered(), checksum_die_context(), clone_as_declaration(), copy_ancestor_tree(), copy_declaration_context(), die_checksum_ordered(), dwarf2out_finish(), generate_type_signature(), get_die_parent(), is_comdat_die(), is_nested_in_subprogram(), optimize_external_refs_1(), splice_child_die(), and strip_naming_typedef().
|
inlinestatic |
|
static |
|
inlinestatic |
Return the value of the string attribute designated by ATTR_KIND, or NULL if it is not present.
References AT_string(), and get_AT().
|
static |
|
inlinestatic |
Return the value of the unsigned attribute designated by ATTR_KIND, or 0 if it is not present.
References AT_unsigned(), and get_AT().
|
static |
Referenced by output_loc_operands(), and size_of_loc_descr().
|
static |
Return die_offset of a DIE reference to a base type.
References calc_base_type_die_sizes(), comp_unit_die(), and die_struct::die_offset.
|
inlinestatic |
|
inlinestatic |
Returns the DIE for a context.
References comp_unit_die(), force_decl_die(), force_type_die(), and strip_naming_typedef().
|
static |
Returns the parent of the declaration of DIE.
References die_struct::die_parent, and get_AT_ref().
Referenced by generate_type_signature().
|
static |
Referenced by output_loc_operands().
|
static |
Return die_offset of a DIE reference other than base type.
References die_struct::die_offset.
|
static |
Referenced by output_loc_operands().
|
static |
Set label to debug_info_section_label + die_offset of a DIE reference.
References die_struct::die_offset.
|
static |
Return the single type-unit die for skeleton type units.
References add_top_level_skeleton_die_attrs(), die_struct::die_abbrev, and new_die().
Referenced by dwarf2out_finish(), output_comdat_type_unit(), and output_skeleton_debug_sections().
|
inlinestatic |
Compute hash of the whole location list LIST_HEAD.
References dw_loc_list_struct::begin, dw_loc_list_struct::dw_loc_next, dw_loc_list_struct::end, dw_loc_list_struct::expr, dw_loc_list_struct::hash, hash_locs(), dw_loc_list_struct::section, and strlen().
Referenced by optimize_location_lists_1().
|
static |
Referenced by hash_loc_operands(), hash_locs(), loc_checksum(), and loc_checksum_ordered().
|
static |
Helper routines for optimize_location_lists. This pass tries to share identical local lists in .debug_loc section.
Iteratively hash operands of LOC opcode.
References addr_table_entry_struct::addr, dw_vec_struct::array, dw_val_struct::dw_val_struct_union::dw_val_die_union::die, dw_loc_descr_struct::dtprel, dw_loc_descr_struct::dw_loc_addr, dw_loc_descr_struct::dw_loc_oprnd1, dw_loc_descr_struct::dw_loc_oprnd2, dw_val_class_addr, dw_val_class_const, dw_val_class_const_double, dw_val_class_loc, dw_val_class_unsigned_const, dw_val_class_vec, dw_vec_struct::elt_size, get_AT_unsigned(), hash_loc_operands(), double_int::high, iterative_hash_rtx(), len, dw_vec_struct::length, double_int::low, offset, addr_table_entry_struct::addr_table_entry_struct_union::rtl, dw_val_struct::v, dw_val_struct::dw_val_struct_union::val_addr, dw_val_struct::val_class, dw_val_struct::dw_val_struct_union::val_die_ref, dw_val_struct::dw_val_struct_union::val_double, dw_val_struct::val_entry, dw_val_struct::dw_val_struct_union::val_int, dw_val_struct::dw_val_struct_union::val_loc, dw_val_struct::dw_val_struct_union::val_unsigned, and dw_val_struct::dw_val_struct_union::val_vec.
|
inlinestatic |
Iteratively hash the whole DWARF location expression LOC.
References dw_loc_descr_struct::dw_loc_next, hash_loc_operands(), and size_of_locs().
Referenced by hash_loc_list().
|
static |
Helper function for loc_descriptor. Return DW_OP_GNU_implicit_pointer for DEBUG_IMPLICIT_PTR RTL.
References dw_val_struct::dw_val_struct_union::dw_val_die_union::die, dw_loc_descr_struct::dw_loc_oprnd1, dw_loc_descr_struct::dw_loc_oprnd2, dw_val_class_const, dw_val_class_decl_ref, dw_val_class_die_ref, dw_val_struct::dw_val_struct_union::dw_val_die_union::external, lookup_decl_die(), new_loc_descr(), dw_val_struct::v, dw_val_struct::val_class, dw_val_struct::dw_val_struct_union::val_decl_ref, and dw_val_struct::dw_val_struct_union::val_die_ref.
Referenced by loc_descriptor().
|
static |
Calculate if the entry should appear in the final output file. It may be from a pruned a type.
References pubname_struct::die, die_struct::die_offset, die_struct::die_parent, die_struct::die_perennial_p, and die_struct::die_tag.
Referenced by output_pubnames(), and size_of_pubnames().
|
static |
A helper function for dwarf2out_finish called through htab_traverse. Assign an addr_table_entry its index. All entries must be collected into the table when this function is called, because the indexing code relies on htab_traverse to traverse nodes in the same order for each run.
References addr_table_entry_struct::index, and addr_table_entry_struct::refcount.
Referenced by dwarf2out_finish().
|
static |
Recursively assign each location list a unique index into the debug_addr section.
References add_addr_table_entry(), AT_class(), AT_loc_list(), ate_kind_label, dw_loc_list_struct::begin, dw_loc_list_struct::begin_entry, die_struct::die_attr, dw_loc_list_struct::dw_loc_next, dw_val_class_loc_list, dw_loc_list_struct::end, and dw_loc_list_struct::force.
Referenced by dwarf2out_finish().
|
static |
A helper function for dwarf2out_finish called through htab_traverse. Assign a string its index. All strings must be collected into the table by the time index_string is called, because the indexing code relies on htab_traverse to traverse nodes in the same order for each run.
References find_string_form(), indirect_string_node::form, indirect_string_node::index, and indirect_string_node::refcount.
Referenced by dwarf2out_finish().
void init_addr_table_entry | ( | ) |
Initialize an addr_table_entry.
References addr_table_entry_struct::addr, ate_kind_label, ate_kind_rtx, ate_kind_rtx_dtprel, addr_table_entry_struct::index, addr_table_entry_struct::kind, addr_table_entry_struct::addr_table_entry_struct_union::label, addr_table_entry_struct::refcount, and addr_table_entry_struct::addr_table_entry_struct_union::rtl.
Referenced by add_addr_table_entry().
|
static |
Referenced by add_const_value_attribute(), and loc_descriptor().
|
static |
Writes double_int values to dw_vec_const array.
References double_int::high, HOST_WIDE_INT, insert_int(), and double_int::low.
|
static |
Referenced by add_const_value_attribute(), loc_descriptor(), and mem_loc_descriptor().
|
static |
Writes floating point values to dw_vec_const array.
References insert_int(), and real_to_target().
|
static |
Referenced by add_const_value_attribute(), insert_double(), insert_float(), and loc_descriptor().
|
static |
Writes integer values to dw_vec_const array.
|
static |
Referenced by add_data_member_location_attribute(), address_of_int_loc_descriptor(), build_cfa_aligned_loc(), compare_loc_descriptor(), descr_info_loc(), int_loc_descriptor(), int_shift_loc_descriptor(), loc_descr_plus_const(), loc_list_from_tree(), mem_loc_descriptor(), minmax_loc_descriptor(), resolve_addr_in_expr(), scompare_loc_descriptor(), and ucompare_loc_descriptor().
|
static |
Return a location descriptor that designates a constant.
References add_loc_descr(), clz_hwi(), ctz_hwi(), HOST_BITS_PER_WIDE_INT, int_loc_descriptor(), int_shift_loc_descriptor(), new_loc_descr(), size_of_int_loc_descriptor(), size_of_sleb128(), and size_of_uleb128().
|
static |
Return a location descriptor that designates a constant i, as a compound operation from constant (i >> shift), constant shift and DW_OP_shl.
References add_loc_descr(), int_loc_descriptor(), and new_loc_descr().
Referenced by int_loc_descriptor().
|
inlinestatic |
Return TRUE if the language is Ada.
References comp_unit_die(), and get_AT_unsigned().
Referenced by dwarf2out_decl(), gen_array_type_die(), and gen_decl_die().
|
static |
Referenced by modified_type_die().
|
inlinestatic |
Given a pointer to an arbitrary ..._TYPE tree node, return nonzero if the given input type is a Dwarf "fundamental" type. Otherwise return null.
|
static |
Referenced by mem_loc_descriptor().
|
inlinestatic |
Return true if this RTL expression describes a base+offset calculation.
|
inlinestatic |
Returns true iff C is a class or structure DIE.
References die_struct::die_tag.
|
static |
Referenced by break_out_includes(), and is_comdat_die().
|
static |
Returns 1 iff C is the sort of DIE that should go into a COMDAT CU. Basically, we want to choose the bits that are likely to be shared between compilations (types) and leave out the bits that are specific to individual compilations (functions).
References die_struct::die_tag, get_AT_ref(), is_comdat_die(), and is_type_die().
|
inlinestatic |
Returns true iff C is a compile-unit DIE.
References die_struct::die_tag.
Referenced by add_pubname(), add_pubtype(), dwarf2out_finish(), gen_struct_or_union_type_die(), and gen_subprogram_die().
|
inlinestatic |
Return TRUE if the language is C++.
References comp_unit_die(), and get_AT_unsigned().
Referenced by add_data_member_location_attribute(), add_pubtype(), generate_type_signature(), and is_naming_typedef_decl().
|
static |
|
static |
Return non-zero if this DIE is a declaration.
References die_struct::die_attr, and dw_attr_struct::dw_attr.
|
inlinestatic |
Return TRUE if the language is Fortran.
References comp_unit_die(), and get_AT_unsigned().
Referenced by add_calling_convention_attribute(), add_subscript_info(), declare_in_namespace(), dwarf2out_decl(), fortran_common(), gen_array_type_die(), gen_decl_die(), gen_descr_array_type_die(), and gen_namespace_die().
|
inlinestatic |
Returns true iff C is a namespace DIE.
References die_struct::die_tag.
Referenced by add_pubname(), and add_pubtype().
|
static |
Referenced by gen_type_die_with_usage(), gen_typedef_die(), and strip_naming_typedef().
|
static |
Return TRUE if TYPE is a typedef that names a type for linkage purposes. This kind of typedefs is produced by the C++ FE for constructs like: typedef struct {...} foo; In that case, there is no typedef variant type produced for foo. Rather, the TREE_TYPE of the TYPE_DECL of foo is the anonymous struct type.
References is_cxx(), is_redundant_typedef(), and is_tagged_type().
|
static |
Return non-zero if this DIE is nested inside a subprogram.
References get_AT_ref(), and local_scope_p().
Referenced by should_move_die_to_comdat().
|
static |
Forward declarations for functions defined in this file.
Referenced by rtl_for_decl_location().
|
inlinestatic |
Test if rtl node points to a pseudo register.
|
inlinestatic |
Referenced by gen_decl_die(), gen_type_die_with_usage(), and is_naming_typedef_decl().
|
inlinestatic |
Is this a typedef we can avoid emitting?
References is_tagged_type().
|
static |
Referenced by assign_symbol_names().
|
static |
Returns 1 iff C is the sort of DIE that might be referred to from another compilation unit.
References die_struct::die_tag, is_declaration_die(), and is_type_die().
|
static |
Referenced by gen_tagged_type_die(), is_naming_typedef_decl(), and is_redundant_typedef().
|
inlinestatic |
Return nonzero if the given type node represents a tagged type.
|
inlinestatic |
Referenced by die_checksum_ordered(), generate_skeleton(), and generate_skeleton_bottom_up().
|
inlinestatic |
Return non-zero if this DIE represents a template instantiation.
References die_struct::die_tag, is_template_parameter(), and is_type_die().
|
inlinestatic |
Return non-zero if this DIE is a template parameter.
References die_struct::die_tag.
Referenced by is_template_instantiation(), and prune_unused_types_mark_generic_parms_dies().
|
static |
|
static |
Returns nonzero if DIE represents a type, in the sense of TYPE_P.
References die_struct::die_tag.
|
inlinestatic |
Returns true iff C is a unit DIE of some sort.
References die_struct::die_tag.
Referenced by copy_ancestor_tree(), copy_declaration_context(), and copy_decls_walk().
|
static |
Referenced by attr_checksum().
|
inlinestatic |
Calculate the checksum of a location expression.
References dw_loc_descr_struct::dtprel, and hash_loc_operands().
|
static |
Referenced by attr_checksum_ordered().
|
inlinestatic |
Calculate the checksum of a location expression.
References dw_loc_descr_struct::dtprel, dw_loc_descr_struct::dw_loc_next, dw_loc_descr_struct::dw_loc_oprnd1, hash_loc_operands(), dw_val_struct::v, and dw_val_struct::dw_val_struct_union::val_unsigned.
bool loc_descr_equal_p | ( | ) |
Compare two complete location expressions for exact equality.
References dw_loc_descr_struct::dw_loc_next, and loc_descr_equal_p_1().
Referenced by cfi_oprnd_equal_p().
|
static |
Compare two location atoms for exact equality.
References dw_loc_descr_struct::dtprel, dw_loc_descr_struct::dw_loc_oprnd1, dw_loc_descr_struct::dw_loc_oprnd2, and dw_val_equal_p().
Referenced by loc_descr_equal_p().
|
static |
Add a constant OFFSET to a location expression.
References add_loc_descr(), dw_loc_descr_struct::dw_loc_next, dw_loc_descr_struct::dw_loc_oprnd1, dw_loc_descr_struct::dw_loc_oprnd2, HOST_WIDE_INT, int_loc_descriptor(), new_loc_descr(), offset, dw_val_struct::v, and dw_val_struct::dw_val_struct_union::val_int.
Referenced by build_cfa_aligned_loc(), descr_info_loc(), loc_list_plus_const(), mem_loc_descriptor(), and tls_mem_loc_descriptor().
|
static |
Output a proper Dwarf location descriptor for a variable or parameter which is either allocated in a register or in a memory location. For a register, we just generate an OP_REG and the register number. For a memory location we provide a Dwarf postfix expression describing how to generate the (dynamic) address of the object onto the address stack. MODE is mode of the decl if this loc_descriptor is going to be used in .debug_loc section where DW_OP_stack_value and DW_OP_implicit_value are allowed, VOIDmode otherwise. If we don't know how to describe it, return 0.
References add_loc_descr(), add_loc_descr_op_piece(), address_of_int_loc_descriptor(), dw_vec_struct::array, avoid_constant_pool_reference(), concat_loc_descriptor(), concatn_loc_descriptor(), const_ok_for_output(), dtprel_false, dw_loc_descr_struct::dw_loc_oprnd2, dw_val_class_const_double, dw_val_class_vec, dw_vec_struct::elt_size, get_address_mode(), implicit_ptr_descriptor(), insert_double(), insert_float(), insert_int(), dw_vec_struct::length, mem_loc_descriptor(), new_addr_loc_descr(), new_loc_descr(), reg_loc_descriptor(), rtx_to_double_int(), subreg_lowpart_p(), tls_mem_loc_descriptor(), double_int::to_shwi(), dw_val_struct::v, dw_val_struct::val_class, dw_val_struct::dw_val_struct_union::val_double, dw_val_struct::dw_val_struct_union::val_vec, and vec_safe_push().
Referenced by concat_loc_descriptor(), concatn_loc_descriptor(), dw_loc_list_1(), and loc_list_from_tree().
|
static |
Referenced by descr_info_loc(), loc_list_from_tree(), and tls_mem_loc_descriptor().
|
static |
Same as above but return only single location expression.
References dw_loc_list_struct::dw_loc_next, expansion_failed(), dw_loc_list_struct::expr, and loc_list_from_tree().
|
static |
Return dw_loc_list representing address of addr_expr LOC by looking for inner INDIRECT_REF expression and turning it into simple arithmetics.
References add_loc_descr_to_each(), add_loc_list(), expansion_failed(), get_inner_reference(), int_size_in_bytes(), loc_list_from_tree(), loc_list_plus_const(), new_loc_descr(), and offset.
Referenced by loc_list_from_tree().
|
static |
|
static |
Generate Dwarf location list representing LOC. If WANT_ADDRESS is false, expression computing LOC will be computed If WANT_ADDRESS is 1, expression computing address of LOC will be returned if WANT_ADDRESS is 2, expression computing address useable in location will be returned (i.e. DW_OP_reg can be used to refer to register values).
References add_loc_descr(), add_loc_descr_to_each(), add_loc_list(), address_of_int_loc_descriptor(), const_ok_for_output(), cst_pool_loc_descr(), decl_address_ip_invariant_p(), do_binop(), do_unop(), dtprel_false, dtprel_true, dw_loc_list(), dw_loc_descr_struct::dw_loc_oprnd1, dw_val_class_loc, expansion_failed(), var_loc_list_def::first, get_address_mode(), get_inner_reference(), host_integerp(), int_loc_descriptor(), int_size_in_bytes(), integer_zerop(), loc_descriptor(), loc_descriptor_from_tree(), loc_list_for_address_of_addr_expr_of_indirect_ref(), loc_list_from_tree(), loc_list_plus_const(), lookup_decl_loc(), mem_loc_descriptor(), new_addr_loc_descr(), new_loc_descr(), new_loc_list(), offset, rtl_for_decl_location(), targetm, tree_low_cst(), dw_val_struct::v, dw_val_struct::val_class, dw_val_struct::dw_val_struct_union::val_loc, and VAR_INIT_STATUS_INITIALIZED.
|
static |
Add a constant OFFSET to a location list.
References dw_loc_list_struct::dw_loc_next, dw_loc_list_struct::expr, and loc_descr_plus_const().
Referenced by gen_variable_die(), loc_list_for_address_of_addr_expr_of_indirect_ref(), and loc_list_from_tree().
|
inlinestatic |
Referenced by gen_subprogram_die(), gen_variable_die(), and is_nested_in_subprogram().
|
inlinestatic |
Returns nonzero if CONTEXT_DIE is internal to a function.
References die_struct::die_parent, and die_struct::die_tag.
|
static |
Referenced by add_abstract_origin_attribute(), add_bound_info(), add_byte_size_attribute(), dwarf2out_abstract_function(), dwarf2out_decl(), dwarf2out_imported_module_or_decl_1(), force_decl_die(), gen_call_site_die(), gen_generic_params_dies(), gen_member_die(), gen_subprogram_die(), gen_tagged_type_die(), gen_type_die_for_member(), gen_variable_die(), implicit_ptr_descriptor(), optimize_location_into_implicit_ptr(), optimize_one_addr_into_implicit_ptr(), parameter_ref_descriptor(), process_scope_var(), resolve_addr(), resolve_addr_in_expr(), scope_die_for(), and string_cst_pool_decl().
|
inlinestatic |
Return the DIE associated with a given declaration.
References decl_die_table.
|
static |
Referenced by add_location_or_const_value_attribute(), and loc_list_from_tree().
|
inlinestatic |
Return the var_loc list associated with a given declaration.
References decl_loc_table.
|
staticread |
Return a pointer to the external_ref for references to DIE.
References hash_table< Descriptor, Allocator >::find_slot(), and external_ref::type.
Referenced by build_abbrev_table(), and optimize_external_refs_1().
|
staticread |
|
staticread |
Lookup FILE_NAME (in the list of filenames that we know about here in dwarf2out.c) and return its "index". The index of each (known) filename is just a unique number which is associated with only that one filename. We need such numbers for the sake of generating labels (in the .debug_sfnames section) and references to those files numbers (in the .debug_srcinfo and.debug_macinfo sections). If the filename given as an argument is not found in our current list, add it to the list and assign it the next available unique index number. In order to speed up searches, we remember the index of the filename was looked up last. This handles the majority of all searches.
References dwarf_file_data::emitted_number, file_table, file_table_last_lookup, and dwarf_file_data::filename.
|
static |
Referenced by add_abstract_origin_attribute(), add_gnat_descriptive_type_attribute(), add_pure_or_virtual_attribute(), base_type_for_mode(), dwarf2out_imported_module_or_decl_1(), force_type_die(), gen_enumeration_type_die(), gen_generic_params_dies(), gen_ptr_to_mbr_type_die(), gen_struct_or_union_type_die(), gen_tagged_type_die(), gen_type_die_with_usage(), gen_typedef_die(), lookup_type_die_strip_naming_typedef(), modified_type_die(), premark_types_used_by_global_vars_helper(), premark_used_types_helper(), and process_scope_var().
|
inlinestatic |
Return the DIE associated with the given type specifier.
|
static |
Referenced by gen_type_die_for_member(), and scope_die_for().
|
inlinestatic |
Like lookup_type_die, but if type is an anonymous type named by a typedef[1], return the DIE of the anonymous type instead the one of the naming typedef. This is because in gen_typedef_die, we did equate the anonymous struct named by the typedef with the DIE of the naming typedef. So by default, lookup_type_die on an anonymous struct yields the DIE of the naming typedef. [1]: Read the comment of is_naming_typedef_decl to learn about what a naming typedef is.
References lookup_type_die(), and strip_naming_typedef().
|
static |
Return the default for DW_AT_lower_bound, or -1 if there is not any default.
References comp_unit_die(), and get_AT_unsigned().
Referenced by add_bound_info(), and gen_descr_array_type_die().
|
static |
Helper function for resolve_addr, mark DW_TAG_base_type nodes referenced from typed stack ops and count how often they are used.
References comp_unit_die(), dw_val_struct::dw_val_struct_union::dw_val_die_union::die, die_struct::die_mark, die_struct::die_parent, dw_loc_descr_struct::dw_loc_next, dw_loc_descr_struct::dw_loc_oprnd1, dw_loc_descr_struct::dw_loc_oprnd2, dw_val_class_unsigned_const, dw_val_struct::v, dw_val_struct::val_class, dw_val_struct::dw_val_struct_union::val_die_ref, and dw_val_struct::dw_val_struct_union::val_loc.
Referenced by resolve_addr().
|
static |
Referenced by copy_decls_for_unworthy_types(), copy_decls_walk(), mark_dies(), output_comdat_type_unit(), and output_comp_unit().
|
static |
Set the marks for a die and its children. We do this so that we know whether or not a reference needs to use FORM_ref_addr; only DIEs in the same CU will be marked. We used to clear out the offset and use that as the flag, but ran into ordering problems.
References die_struct::die_mark, and mark_dies().
|
static |
Match the base name of a file to the base name of a compilation unit.
References base_of_path(), and path.
Referenced by should_emit_struct_debug().
|
static |
Referenced by dwarf2out_source_line(), output_die(), output_macinfo_op(), size_of_die(), and value_format().
|
static |
If the assembler will construct the file table, then translate the compiler internal file table number into the assembler file table number, and emit a .file directive if we haven't already emitted one yet. The file table numbers are different because we prune debug info for unused variables and types, which may include filenames.
References asm_out_file, dwarf_file_data::emitted_number, dwarf_file_data::filename, output_quoted_string(), and remap_debug_filename().
|
read |
The following routine converts the RTL for a variable or parameter (resident in memory) into an equivalent Dwarf representation of a mechanism for getting the address of that same variable onto the top of a hypothetical "address evaluation" stack. When creating memory location descriptors, we are effectively transforming the RTL for a memory-resident object into its Dwarf postfix expression equivalent. This routine recursively descends an RTL tree, turning it into Dwarf postfix code as it goes. MODE is the mode that should be assumed for the rtl if it is VOIDmode. MEM_MODE is the mode of the memory reference, needed to handle some autoincrement addressing modes. Return 0 if we can't represent the location.
References add_loc_descr(), dw_vec_struct::array, avoid_constant_pool_reference(), base_type_for_mode(), based_loc_descr(), bswap_loc_descriptor(), clz_loc_descriptor(), const_ok_for_output(), convert_descriptor_to_mode(), dbx_reg_number(), dw_val_struct::dw_val_struct_union::dw_val_die_union::die, do_binop(), do_unop(), dtprel_false, dtprel_true, dw_loc_descr_struct::dw_loc_oprnd1, dw_loc_descr_struct::dw_loc_oprnd2, dw_val_class_const, dw_val_class_const_double, dw_val_class_die_ref, dw_val_class_loc, dw_val_class_vec, dw_vec_struct::elt_size, expansion_failed(), dw_val_struct::dw_val_struct_union::dw_val_die_union::external, double_int::from_shwi(), get_address_mode(), HOST_BITS_PER_WIDE_INT, insert_float(), int_loc_descriptor(), is_based_loc(), dw_vec_struct::length, loc_descr_plus_const(), mem_loc_descriptor(), minmax_loc_descriptor(), mode_for_size(), new_addr_loc_descr(), new_loc_descr(), one_reg_loc_descriptor(), parameter_ref_descriptor(), popcount_loc_descriptor(), print_rtl(), ptr_mode, resolve_one_addr(), rotate_loc_descriptor(), rtx_to_double_int(), scompare_loc_descriptor(), shift, size_of_int_loc_descriptor(), subreg_lowpart_p(), targetm, tls_mem_loc_descriptor(), TLS_MODEL_NONE, trunc_int_for_mode(), typed_binop(), ucompare_loc_descriptor(), dw_val_struct::v, dw_val_struct::val_class, dw_val_struct::dw_val_struct_union::val_die_ref, dw_val_struct::dw_val_struct_union::val_double, dw_val_struct::dw_val_struct_union::val_loc, dw_val_struct::dw_val_struct_union::val_vec, VAR_INIT_STATUS_INITIALIZED, VAR_INIT_STATUS_UNINITIALIZED, vec_safe_push(), and word_mode.
Referenced by bswap_loc_descriptor(), clz_loc_descriptor(), cst_pool_loc_descr(), dw_loc_list_1(), dwarf2out_frame_debug_cfa_expression(), gen_subprogram_die(), loc_descriptor(), loc_list_from_tree(), mem_loc_descriptor(), minmax_loc_descriptor(), popcount_loc_descriptor(), reg_loc_descriptor(), rotate_loc_descriptor(), scompare_loc_descriptor(), typed_binop(), and ucompare_loc_descriptor().
|
static |
Referenced by gen_decl_die(), gen_field_die(), and gen_type_die_for_member().
|
inlinestatic |
Return the type associated with a data member, make a special check for bit field types.
|
static |
Return location descriptor for {U,S}{MIN,MAX}.
References add_loc_descr(), base_type_for_mode(), convert_descriptor_to_mode(), dw_val_struct::dw_val_struct_union::dw_val_die_union::die, dw_loc_descr_struct::dw_loc_oprnd1, dw_val_class_die_ref, dw_val_class_loc, dw_val_struct::dw_val_struct_union::dw_val_die_union::external, int_loc_descriptor(), mem_loc_descriptor(), new_loc_descr(), shift, dw_val_struct::v, dw_val_struct::val_class, dw_val_struct::dw_val_struct_union::val_die_ref, dw_val_struct::dw_val_struct_union::val_loc, and VAR_INIT_STATUS_INITIALIZED.
Referenced by mem_loc_descriptor().
|
static |
Given a pointer to an arbitrary ..._TYPE tree node, return a debugging entry that chains various modifiers in front of the given type.
References add_AT_die_ref(), add_AT_flag(), add_AT_unsigned(), add_gnat_descriptive_type_attribute(), add_name_attribute(), base_type_die(), die_struct::die_tag, equate_type_number_to_die(), gen_type_die(), get_qualified_type(), is_base_type(), lookup_type_die(), new_die(), scope_die_for(), simple_type_size_in_bits(), subrange_type_die(), subrange_type_for_debug_p(), type_main_variant(), TYPE_QUAL_CONST, and TYPE_QUAL_VOLATILE.
Referenced by add_type_attribute(), base_type_for_mode(), and force_type_die().
|
static |
Move all children from OLD_PARENT to NEW_PARENT.
References die_struct::die_child, and die_struct::die_parent.
Referenced by generate_skeleton_bottom_up().
|
inlinestatic |
Move a DW_AT_{,MIPS_}linkage_name attribute just added to dw_die_ref to the location it would have been added, should we know its DECL_ASSEMBLER_NAME when we added other attributes. This will probably improve compactness of debug info, removing equivalent abbrevs, and hide any differences caused by deferring the computation of the assembler name, triggered by e.g. PCH.
References die_struct::die_attr, dw_attr_struct::dw_attr, and vec_safe_length().
Referenced by dwarf2out_finish().
|
static |
Move base types marked by mark_base_types as early as possible in the CU, sorted by decreasing usage count both to make the uleb128 references as small as possible and to make sure they will have die_offset already computed by calc_die_sizes when sizes of typed stack loc ops is computed.
References base_type_cmp(), comp_unit_die(), die_struct::die_child, die_struct::die_mark, die_struct::die_sib, and remove_child_with_prev().
Referenced by dwarf2out_finish().
|
static |
Given an RTL of a register, return a location descriptor that designates a value that spans more than one register.
References add_loc_descr(), add_loc_descr_op_piece(), dbx_reg_number(), new_loc_descr(), one_reg_loc_descriptor(), VAR_INIT_STATUS_INITIALIZED, and VAR_INIT_STATUS_UNINITIALIZED.
Referenced by reg_loc_descriptor().
|
static |
Helper function for tree_add_const_value_attribute. Natively encode initializer INIT into an array. Return true if successful.
References count, host_integerp(), constructor_elt_d::index, int_byte_position(), int_size_in_bytes(), memcpy(), memset(), native_encode_expr(), tree_low_cst(), type(), and constructor_elt_d::value.
Referenced by tree_add_const_value_attribute().
|
inlinestatic |
Return a pointer to a newly allocated address location description. If dwarf_split_debug_info is true, then record the address with the appropriate relocation.
References add_addr_table_entry(), ate_kind_rtx, ate_kind_rtx_dtprel, dw_loc_descr_struct::dtprel, dw_addr_op(), dw_loc_descr_struct::dw_loc_oprnd1, dw_val_class_addr, new_loc_descr(), dw_val_struct::v, dw_val_struct::dw_val_struct_union::val_addr, dw_val_struct::val_class, and dw_val_struct::val_entry.
Referenced by add_const_value_attribute(), loc_descriptor(), loc_list_from_tree(), and mem_loc_descriptor().
|
static |
Referenced by add_bound_info(), add_subscript_info(), base_type_die(), break_out_comdat_types(), change_AT_die_ref(), dwarf2_build_local_stub(), dwarf2out_end_source_file(), dwarf2out_imported_module_or_decl_1(), dwarf2out_start_source_file(), gen_array_type_die(), gen_call_site_die(), gen_compile_unit_die(), gen_const_die(), gen_descr_array_type_die(), gen_entry_point_die(), gen_enumeration_type_die(), gen_field_die(), gen_formal_parameter_die(), gen_formal_parameter_pack_die(), gen_inheritance_die(), gen_inlined_subroutine_die(), gen_label_die(), gen_lexical_block_die(), gen_namespace_die(), gen_pointer_type_die(), gen_ptr_to_mbr_type_die(), gen_reference_type_die(), gen_struct_or_union_type_die(), gen_subprogram_die(), gen_subroutine_type_die(), gen_type_die_with_usage(), gen_typedef_die(), gen_unspecified_parameters_die(), gen_variable_die(), generic_parameter_die(), get_skeleton_type_unit(), modified_type_die(), string_cst_pool_decl(), subrange_type_die(), and template_parameter_pack_die().
|
inlinestatic |
Return a pointer to a newly created DIE node.
References add_child_die(), limbo_die_struct::created_for, limbo_die_struct::die, die_struct::die_tag, limbo_die_list, and limbo_die_struct::next.
|
static |
Create a new line number table.
References dw_line_info_table_struct::file_num, dw_line_info_table_struct::is_stmt, dw_line_info_table_struct::line_num, and table.
Referenced by dwarf2out_init(), and set_cur_line_info_table().
|
inlinestatic |
Return a pointer to a newly allocated location description. Location descriptions are simple expression terms that can be strung together to form more complicated location (address) descriptions.
References dw_loc_descr_struct::dw_loc_oprnd1, dw_loc_descr_struct::dw_loc_oprnd2, dw_val_class_unsigned_const, dw_val_struct::v, dw_val_struct::val_class, dw_val_struct::val_entry, and dw_val_struct::dw_val_struct_union::val_unsigned.
Referenced by add_const_value_attribute(), add_data_member_location_attribute(), add_loc_descr_op_piece(), add_pure_or_virtual_attribute(), address_of_int_loc_descriptor(), based_loc_descr(), bswap_loc_descriptor(), build_cfa_aligned_loc(), build_cfa_loc(), clz_loc_descriptor(), compare_loc_descriptor(), concat_loc_descriptor(), concatn_loc_descriptor(), convert_descriptor_to_mode(), descr_info_loc(), dw_loc_list_1(), gen_subprogram_die(), implicit_ptr_descriptor(), int_loc_descriptor(), int_shift_loc_descriptor(), loc_descr_plus_const(), loc_descriptor(), loc_list_for_address_of_addr_expr_of_indirect_ref(), loc_list_from_tree(), mem_loc_descriptor(), minmax_loc_descriptor(), multiple_reg_loc_descriptor(), new_addr_loc_descr(), new_loc_descr_op_bit_piece(), new_reg_loc_descr(), one_reg_loc_descriptor(), optimize_location_into_implicit_ptr(), parameter_ref_descriptor(), popcount_loc_descriptor(), reg_loc_descriptor(), resolve_addr_in_expr(), rotate_loc_descriptor(), scompare_loc_descriptor(), string_cst_pool_decl(), typed_binop(), and ucompare_loc_descriptor().
|
static |
Create a DW_OP_piece or DW_OP_bit_piece for bitsize, or return NULL if it is not possible.
References new_loc_descr().
Referenced by dw_sra_loc_expr().
|
inlinestatic |
Return a new location list, given the begin and end range, and the expression.
References dw_loc_list_struct::begin, dw_loc_list_struct::begin_entry, dw_loc_list_struct::end, dw_loc_list_struct::expr, and dw_loc_list_struct::section.
Referenced by convert_cfa_to_fb_loc_list(), dw_loc_list(), and loc_list_from_tree().
|
inlinestatic |
Return a pointer to a newly allocated location description for REG and OFFSET.
References new_loc_descr().
Referenced by based_loc_descr(), build_cfa_aligned_loc(), and build_cfa_loc().
|
static |
Referenced by mem_loc_descriptor(), multiple_reg_loc_descriptor(), and reg_loc_descriptor().
|
static |
Return a location descriptor that designates a machine register for a given hard register number.
References add_loc_descr(), new_loc_descr(), and VAR_INIT_STATUS_UNINITIALIZED.
|
static |
DIE is a unit; look through all the DIE references to see if there are any external references to types, and if so, create local stubs for them which will be applied in build_abbrev_table. This is useful because references to local DIEs are smaller.
References hash_table< Descriptor, Allocator >::create(), dwarf2_build_local_stub(), map, optimize_external_refs_1(), and hash_table< Descriptor, Allocator >::traverse().
Referenced by output_comdat_type_unit(), and output_comp_unit().
|
static |
Subroutine of optimize_external_refs, below. If we see a type skeleton, record it as our stub. If we see external references, remember how many we've seen.
References AT_class(), AT_ref(), die_struct::die_attr, dw_val_class_die_ref, get_AT_ref(), is_type_die(), lookup_external_ref(), external_ref::n_refs, and external_ref::stub.
Referenced by optimize_external_refs().
|
static |
Helper function of resolve_addr. DIE had DW_AT_location of DW_OP_addr alone, which referred to DECL in DW_OP_addr's operand and DW_OP_addr couldn't be resolved. resolve_addr has already removed the DW_AT_location attribute. This function attempts to add a new DW_AT_location attribute with DW_OP_GNU_implicit_pointer to it or DW_AT_const_value attribute, if possible.
References add_AT_loc(), dw_val_struct::dw_val_struct_union::dw_val_die_union::die, dw_loc_descr_struct::dw_loc_oprnd1, dw_val_class_die_ref, dw_val_struct::dw_val_struct_union::dw_val_die_union::external, get_AT(), host_integerp(), lookup_decl_die(), new_loc_descr(), offset, string_cst_pool_decl(), tree_add_const_value_attribute(), tree_low_cst(), dw_val_struct::v, dw_val_struct::val_class, and dw_val_struct::dw_val_struct_union::val_die_ref.
Referenced by resolve_addr().
|
static |
Optimize location lists referenced from DIE children and share them whenever possible.
References hash_table< Descriptor, Allocator >::create(), hash_table< Descriptor, Allocator >::dispose(), and optimize_location_lists_1().
Referenced by dwarf2out_finish().
|
static |
Recursively optimize location lists referenced from DIE children and share them whenever possible.
References AT_class(), AT_loc_list(), die_struct::die_attr, dw_attr_struct::dw_attr_val, dw_val_class_loc_list, hash_table< Descriptor, Allocator >::find_slot_with_hash(), dw_loc_list_struct::hash, hash_loc_list(), dw_val_struct::v, and dw_val_struct::dw_val_struct_union::val_loc_list.
Referenced by optimize_location_lists().
|
static |
Attempt to make a sequence of define/undef macinfo ops shareable with other compilation unit .debug_macinfo sections. IDX is the first index of a define/undef, return the number of ops that should be emitted in a comdat .debug_macinfo section and emit a DW_MACRO_GNU_transparent_include entry referencing it. If the define/undef entry should be emitted normally, return 0.
References checksum_uleb128(), macinfo_struct::code, count, hash_table< Descriptor, Allocator >::create(), hash_table< Descriptor, Allocator >::elements(), hash_table< Descriptor, Allocator >::find_slot(), first, HOST_WIDE_INT, HOST_WIDE_INT_PRINT_UNSIGNED, macinfo_struct::info, hash_table< Descriptor, Allocator >::is_created(), macinfo_struct::lineno, memcpy(), output_macinfo_op(), strlen(), and vec_safe_is_empty().
Referenced by output_macinfo().
|
static |
Helper function of resolve_addr_in_expr. LOC is a DW_OP_addr followed by DW_OP_stack_value, either at the start of exprloc or after DW_OP_{,bit_}piece, and val_addr can't be resolved. Replace it (both DW_OP_addr and DW_OP_stack_value) with DW_OP_GNU_implicit_pointer if possible and return true, if unsuccessful, return false.
References build_array_type(), build_index_type(), build_string(), dw_val_struct::dw_val_struct_union::dw_val_die_union::die, dw_loc_descr_struct::dw_loc_next, dw_loc_descr_struct::dw_loc_oprnd1, dw_loc_descr_struct::dw_loc_oprnd2, dw_val_class_die_ref, dw_val_struct::dw_val_struct_union::dw_val_die_union::external, get_AT(), len, lookup_decl_die(), offset, string_cst_pool_decl(), strlen(), dw_val_struct::v, dw_val_struct::dw_val_struct_union::val_addr, dw_val_struct::val_class, dw_val_struct::dw_val_struct_union::val_die_ref, dw_val_struct::val_entry, and dw_val_struct::dw_val_struct_union::val_int.
Referenced by resolve_addr_in_expr().
|
static |
Output the .debug_abbrev section which defines the DIE abbreviation table.
References abbrev_die_table_in_use, dw2_asm_output_data(), and output_die_abbrevs().
Referenced by dwarf2out_finish().
|
static |
Produce the .debug_addr section.
References addr_index_table, output_addr_table_entry(), and switch_to_section().
Referenced by dwarf2out_finish().
|
static |
Callback for htab_traverse to assign an index to an entry in the table, and to write that entry to the .debug_addr section.
References addr_table_entry_struct::addr, asm_out_file, ate_kind_label, ate_kind_rtx, ate_kind_rtx_dtprel, dw2_asm_output_addr(), dw2_asm_output_addr_rtx(), addr_table_entry_struct::index, addr_table_entry_struct::kind, addr_table_entry_struct::addr_table_entry_struct_union::label, addr_table_entry_struct::refcount, addr_table_entry_struct::addr_table_entry_struct_union::rtl, and targetm.
Referenced by output_addr_table().
|
static |
Referenced by dwarf2out_finish().
|
static |
Output the information that goes into the .debug_aranges table. Namely, define the beginning and ending address range of the text section generated for this compilation unit.
References cold_text_section_used, dw_fde_struct::decl, dw2_asm_output_addr(), dw2_asm_output_data(), dw2_asm_output_delta(), dw2_asm_output_offset(), dw_fde_struct::dw_fde_begin, dw_fde_struct::dw_fde_end, dw_fde_struct::dw_fde_second_begin, dw_fde_struct::dw_fde_second_end, fde_vec, have_multiple_function_sections, dw_fde_struct::in_std_section, dw_fde_struct::second_in_std_section, and text_section_used.
|
static |
Output an attribute's index or value appropriately.
References AT_addr(), AT_class(), AT_index(), AT_lbl(), dw2_asm_output_addr(), dw2_asm_output_addr_rtx(), dw2_asm_output_data_uleb128(), dw_attr_struct::dw_attr, dw_val_class_addr, dw_val_class_high_pc, dw_val_class_lbl_id, dw_val_class_loc_list, dwarf_attr_name(), and output_loc_list_offset().
Referenced by output_die().
|
static |
Referenced by dwarf2out_frame_finish().
|
static |
Output the call frame information used to record information that relates to calculating the frame pointer, and records the location of saved registers.
References app_disable(), app_enable(), asm_out_file, assemble_external_libcall(), cie_cfi_vec, current_unit_personality, dw_fde_struct::decl, dw2_asm_output_data(), dw2_asm_output_data_sleb128(), dw2_asm_output_data_uleb128(), dw2_asm_output_delta(), dw2_asm_output_encoded_addr_rtx(), dw2_asm_output_nstring(), dw_fde_struct::dw_fde_second_begin, dwarf2out_do_cfi_asm(), eh_data_format_name(), fde_needed_for_eh_p(), fde_vec, floor_log2(), offset, output_cfi(), output_fde(), size_of_encoded_value(), size_of_sleb128(), size_of_uleb128(), strlen(), switch_to_frame_table_section(), targetm, and dw_fde_struct::uses_eh_lsda.
|
static |
Referenced by dwarf2out_finish().
|
static |
Output a comdat type unit DIE and its children.
References build_abbrev_table(), calc_die_sizes(), die_struct::die_offset, hash_table< Descriptor, Allocator >::dispose(), dw2_asm_output_data(), dw2_asm_output_offset(), get_identifier(), get_section(), get_skeleton_type_unit(), mark_dies(), optimize_external_refs(), output_compilation_unit_header(), output_die(), output_signature(), comdat_type_struct::root_die, comdat_type_struct::signature, size_of_die(), switch_to_section(), targetm, comdat_type_struct::type_die, and unmark_dies().
|
static |
Referenced by dwarf2out_finish().
|
static |
Output the compilation unit DIE and its children.
References asm_out_file, build_abbrev_table(), calc_die_sizes(), die_struct::die_child, die_struct::die_id, die_struct::die_symbol_or_type_node::die_symbol, hash_table< Descriptor, Allocator >::dispose(), get_section(), mark_dies(), optimize_external_refs(), output_compilation_unit_header(), output_die(), strlen(), switch_to_section(), and unmark_dies().
|
static |
Output the compilation unit that appears at the beginning of the .debug_info section, and precedes the DIE descriptions.
References dw2_asm_output_data(), and dw2_asm_output_offset().
Referenced by output_comdat_type_unit(), and output_comp_unit().
|
static |
Referenced by output_comdat_type_unit(), output_comp_unit(), output_die(), and output_skeleton_debug_sections().
|
static |
Output the DIE and its attributes. Called recursively to generate the definitions of each child DIE.
References dw_vec_struct::array, asm_out_file, AT_class(), AT_flag(), AT_index(), AT_int(), AT_lbl(), AT_loc(), AT_ref(), AT_ref_external(), AT_string(), AT_unsigned(), AT_vms_delta1(), AT_vms_delta2(), die_struct::comdat_type_p, constant_size(), die_struct::die_abbrev, die_struct::die_attr, die_struct::die_child, die_struct::die_id, die_struct::die_offset, die_struct::die_symbol_or_type_node::die_symbol, die_struct::die_tag, die_struct::die_symbol_or_type_node::die_type_node, dw2_asm_output_data(), dw2_asm_output_data_sleb128(), dw2_asm_output_data_uleb128(), dw2_asm_output_delta(), dw2_asm_output_nstring(), dw2_asm_output_offset(), dw2_asm_output_vms_delta(), dw_attr_struct::dw_attr, dw_attr_struct::dw_attr_val, dw_val_class_addr, dw_val_class_const, dw_val_class_const_double, dw_val_class_data8, dw_val_class_die_ref, dw_val_class_fde_ref, dw_val_class_file, dw_val_class_flag, dw_val_class_high_pc, dw_val_class_lbl_id, dw_val_class_lineptr, dw_val_class_loc, dw_val_class_loc_list, dw_val_class_macptr, dw_val_class_offset, dw_val_class_range_list, dw_val_class_str, dw_val_class_unsigned_const, dw_val_class_vec, dw_val_class_vms_delta, dwarf_attr_name(), dwarf_tag_name(), dw_vec_struct::elt_size, extract_int(), dwarf_file_data::filename, first, indirect_string_node::form, get_AT_low_pc(), double_int::high, HOST_BITS_PER_CHAR, HOST_BITS_PER_WIDE_INT, indirect_string_node::label, len, dw_vec_struct::length, double_int::low, maybe_emit_file(), output_attr_index_or_value(), output_die(), output_die_symbol(), output_loc_sequence(), output_range_list_offset(), output_signature(), comdat_type_struct::signature, size_of_locs(), dw_val_struct::v, dw_val_struct::dw_val_struct_union::val_data8, dw_val_struct::dw_val_struct_union::val_double, dw_val_struct::dw_val_struct_union::val_fde_index, dw_val_struct::dw_val_struct_union::val_file, dw_val_struct::dw_val_struct_union::val_offset, dw_val_struct::dw_val_struct_union::val_str, and dw_val_struct::dw_val_struct_union::val_vec.
|
static |
Referenced by output_abbrev_section(), and output_skeleton_debug_sections().
|
static |
Given a die and id, produce the appropriate abbreviations.
References die_struct::die_attr, die_struct::die_child, die_struct::die_tag, dw2_asm_output_data(), dw2_asm_output_data_uleb128(), dw_attr_struct::dw_attr, dwarf_attr_name(), dwarf_tag_name(), output_value_format(), and vec_safe_iterate().
|
static |
Referenced by output_die().
|
inlinestatic |
Output a symbol we can use to refer to this DIE from another CU.
References asm_out_file, die_struct::comdat_type_p, die_struct::die_id, die_struct::die_symbol_or_type_node::die_symbol, and targetm.
|
static |
Output one FDE.
References asm_out_file, dw_fde_struct::decl, dw2_asm_output_addr(), dw2_asm_output_data(), dw2_asm_output_data_uleb128(), dw2_asm_output_delta(), dw2_asm_output_encoded_addr_rtx(), dw2_asm_output_offset(), dw_fde_struct::dw_fde_begin, dw_fde_struct::dw_fde_cfi, dw_fde_struct::dw_fde_current_label, dw_fde_struct::dw_fde_end, dw_fde_struct::dw_fde_second_begin, dw_fde_struct::dw_fde_second_end, dw_fde_struct::dw_fde_switch_cfi_index, floor_log2(), dw_fde_struct::funcdef_number, function_section(), offset, output_cfi(), size_of_encoded_value(), size_of_uleb128(), switch_to_frame_table_section(), switch_to_section(), targetm, dw_fde_struct::uses_eh_lsda, and vec_safe_length().
Referenced by output_call_frame_info().
|
static |
Output the directory table and the file name table. We try to minimize the total amount of memory needed. A heuristic is used to avoid large slowdowns with many input files.
References count, dir_info::count, file_info::dir_idx, dir_info::dir_idx, dw2_asm_output_data(), dw2_asm_output_data_uleb128(), dw2_asm_output_nstring(), file_info_cmp(), file_name_acquire(), file_table, file_name_acquire_data::files, file_info::fname, dir_info::length, file_name_acquire_data::max_files, memset(), path, file_info::path, dir_info::path, dir_info::prefix, snprintf(), strlen(), file_name_acquire_data::used_files, and vms_file_stats_name().
Referenced by output_line_info().
|
static |
A helper function for dwarf2out_finish called through htab_traverse. Output the indexed string.
References assemble_string(), indirect_string_node::form, indirect_string_node::index, indirect_string_node::refcount, indirect_string_node::str, and strlen().
Referenced by output_indirect_strings().
|
static |
A helper function for output_indirect_strings called through htab_traverse. Output the offset to a string and update the current offset.
References dw2_asm_output_data(), indirect_string_node::form, indirect_string_node::index, offset, indirect_string_node::refcount, indirect_string_node::str, and strlen().
Referenced by output_indirect_strings().
|
static |
And now, the support for symbolic debugging information.
.debug_str support.
Referenced by output_indirect_strings().
|
static |
A helper function for dwarf2out_finish called through htab_traverse. Emit one queued .debug_str string.
References asm_out_file, assemble_string(), find_string_form(), indirect_string_node::form, indirect_string_node::label, indirect_string_node::refcount, indirect_string_node::str, and strlen().
|
static |
Output the indexed string table.
References offset, output_index_string(), output_index_string_offset(), output_indirect_string(), and switch_to_section().
Referenced by dwarf2out_finish().
|
static |
Referenced by dwarf2out_finish().
|
static |
Output the source line number correspondence information. This information goes into the .debug_line section.
References asm_out_file, dw2_asm_output_data(), dw2_asm_output_delta(), dw_line_info_table_struct::in_use, output_file_names(), output_one_line_info_table(), and table.
|
static |
Referenced by output_location_lists().
|
static |
Output the location list given to us.
References asm_out_file, dw_loc_list_struct::begin, dw_loc_list_struct::begin_entry, dw2_asm_output_addr(), dw2_asm_output_data(), dw2_asm_output_data_uleb128(), dw2_asm_output_delta(), dw_loc_list_struct::dw_loc_next, dw_loc_list_struct::emitted, dw_loc_list_struct::end, dw_loc_list_struct::expr, dw_loc_list_struct::force, have_multiple_function_sections, addr_table_entry_struct::index, dw_loc_list_struct::ll_symbol, output_loc_sequence(), dw_loc_list_struct::section, and size_of_locs().
|
static |
Output the offset into the debug_loc section.
References AT_loc_list(), dw2_asm_output_delta(), dw2_asm_output_offset(), dw_attr_struct::dw_attr, dwarf_attr_name(), and dw_loc_list_struct::ll_symbol.
Referenced by output_attr_index_or_value().
|
static |
Output location description stack opcode's operands (if any). The for_eh_or_skip parameter controls whether register numbers are converted using DWARF2_FRAME_REG_OUT, which is needed in the case that hard reg numbers have been processed via DWARF_FRAME_REGNUM (i.e. for unwind info). This should be suppressed for the cases that have not been converted (i.e. symbolic debug info), by setting the parameter < 0. See PR47324.
References dw_vec_struct::array, asm_out_file, dw_val_struct::dw_val_struct_union::dw_val_die_union::die, dw_loc_descr_struct::dtprel, dw2_asm_output_addr_rtx(), dw2_asm_output_data(), dw2_asm_output_data_sleb128(), dw2_asm_output_data_uleb128(), dw2_asm_output_offset(), dw_loc_descr_struct::dw_loc_addr, dw_loc_descr_struct::dw_loc_oprnd1, dw_loc_descr_struct::dw_loc_oprnd2, dw_val_class_addr, dw_val_class_const, dw_val_class_const_double, dw_val_class_die_ref, dw_val_class_loc, dw_val_class_unsigned_const, dw_val_class_vec, dw_vec_struct::elt_size, extract_int(), first, get_base_type_offset(), get_ref_die_offset(), get_ref_die_offset_label(), double_int::high, HOST_BITS_PER_CHAR, HOST_BITS_PER_WIDE_INT, HOST_WIDE_INT, addr_table_entry_struct::index, len, dw_vec_struct::length, double_int::low, offset, output_loc_sequence(), size_of_locs(), size_of_uleb128(), targetm, dw_val_struct::v, dw_val_struct::dw_val_struct_union::val_addr, dw_val_struct::val_class, dw_val_struct::dw_val_struct_union::val_die_ref, dw_val_struct::dw_val_struct_union::val_double, dw_val_struct::val_entry, dw_val_struct::dw_val_struct_union::val_int, dw_val_struct::dw_val_struct_union::val_loc, dw_val_struct::dw_val_struct_union::val_unsigned, and dw_val_struct::dw_val_struct_union::val_vec.
Referenced by output_loc_sequence().
|
static |
Output location description stack opcode's operands (if any). The output is single bytes on a line, suitable for .cfi_escape.
References asm_out_file, dw2_asm_output_data_raw(), dw2_asm_output_data_sleb128_raw(), dw2_asm_output_data_uleb128_raw(), dw_loc_descr_struct::dw_loc_addr, dw_loc_descr_struct::dw_loc_oprnd1, dw_loc_descr_struct::dw_loc_oprnd2, dw_val_class_loc, HOST_BITS_PER_WIDE_INT, offset, size_of_uleb128(), dw_val_struct::v, dw_val_struct::val_class, dw_val_struct::dw_val_struct_union::val_int, dw_val_struct::dw_val_struct_union::val_loc, and dw_val_struct::dw_val_struct_union::val_unsigned.
Referenced by output_loc_sequence_raw().
void output_loc_sequence | ( | ) |
Output a sequence of location operations. The for_eh_or_skip parameter controls whether register numbers are converted using DWARF2_FRAME_REG_OUT, which is needed in the case that hard reg numbers have been processed via DWARF_FRAME_REGNUM (i.e. for unwind info). This should be suppressed for the cases that have not been converted (i.e. symbolic debug info), by setting the parameter < 0. See PR47324.
References dw2_asm_output_data(), dw_loc_descr_struct::dw_loc_next, dwarf_stack_op_name(), and output_loc_operands().
Referenced by output_cfa_loc(), output_die(), output_loc_list(), and output_loc_operands().
void output_loc_sequence_raw | ( | ) |
References asm_out_file, dw_loc_descr_struct::dw_loc_next, and output_loc_operands_raw().
Referenced by output_cfa_loc_raw().
|
static |
Referenced by dwarf2out_finish(), and output_location_lists().
|
static |
Output all location lists for the DIE and its children.
References AT_class(), AT_loc_list(), die_struct::die_attr, dw_val_class_loc_list, output_loc_list(), and output_location_lists().
|
static |
Output macinfo section(s).
References asm_out_file, macinfo_struct::code, count, hash_table< Descriptor, Allocator >::dispose(), dw2_asm_output_data(), dw2_asm_output_offset(), get_identifier(), macinfo_struct::info, hash_table< Descriptor, Allocator >::is_created(), macinfo_struct::lineno, optimize_macinfo_range(), output_macinfo_op(), targetm, vec_safe_is_empty(), vec_safe_length(), and vec_safe_push().
Referenced by dwarf2out_finish().
|
static |
Output a single .debug_macinfo entry.
References asm_out_file, macinfo_struct::code, dw2_asm_output_data(), dw2_asm_output_data_uleb128(), dw2_asm_output_nstring(), dw2_asm_output_offset(), find_AT_string(), indirect_string_node::form, indirect_string_node::index, macinfo_struct::info, indirect_string_node::label, len, macinfo_struct::lineno, lookup_filename(), maybe_emit_file(), and strlen().
Referenced by optimize_macinfo_range(), and output_macinfo().
|
static |
Output one line number table into the .debug_line section.
References dw2_asm_output_addr(), dw2_asm_output_data(), dw2_asm_output_data_sleb128(), dw2_asm_output_data_uleb128(), dw_line_info_table_struct::end_label, dw_line_info_table_struct::entries, LI_negate_stmt, LI_set_address, LI_set_column, LI_set_discriminator, LI_set_epilogue_begin, LI_set_file, LI_set_line, LI_set_prologue_end, dw_line_info_struct::opcode, size_of_uleb128(), and dw_line_info_struct::val.
Referenced by output_line_info().
|
static |
Referenced by dwarf2out_finish().
|
static |
Output the public names table used to speed up access to externally visible names; or the public types table used to find type definitions.
References die_struct::comdat_type_p, pubname_struct::die, die_struct::die_id, die_struct::die_mark, die_struct::die_offset, die_struct::die_tag, die_struct::die_symbol_or_type_node::die_type_node, dw2_asm_output_data(), dw2_asm_output_nstring(), dw2_asm_output_offset(), include_pubname_in_output(), pubname_struct::name, size_of_pubnames(), comdat_type_struct::skeleton_die, switch_to_section(), and want_pubnames().
|
static |
Output a range_list offset into the debug_range section. Emit a relocated reference if val_entry is NULL, otherwise, emit an indirect reference.
References dw2_asm_output_data(), dw2_asm_output_offset(), dw_attr_struct::dw_attr, dw_attr_struct::dw_attr_val, dwarf_attr_name(), HOST_WIDE_INT_PRINT_HEX, dw_val_struct::v, dw_val_struct::val_entry, and dw_val_struct::dw_val_struct_union::val_offset.
Referenced by output_die().
|
static |
References dw2_asm_output_addr(), dw2_asm_output_data(), dw2_asm_output_delta(), have_multiple_function_sections, dw_ranges_struct::num, and ranges_table_in_use.
Referenced by dwarf2out_finish().
|
inlinestatic |
Output a type signature.
References dw2_asm_output_data().
Referenced by output_comdat_type_unit(), and output_die().
|
static |
Output skeleton debug sections that point to the dwo file.
References asm_out_file, die_struct::die_abbrev, dw2_asm_output_data(), dw2_asm_output_offset(), get_skeleton_type_unit(), output_die(), output_die_abbrevs(), remove_AT(), size_of_die(), and switch_to_section().
Referenced by dwarf2out_finish().
|
static |
Referenced by output_die_abbrevs().
|
static |
Output the encoding of an attribute value.
References dw2_asm_output_data_uleb128(), dwarf_form_name(), and value_format().
|
static |
Helper function for mem_loc_descriptor. Return DW_OP_GNU_parameter_ref for DEBUG_PARAMETER_REF RTL.
References dw_val_struct::dw_val_struct_union::dw_val_die_union::die, dw_loc_descr_struct::dw_loc_oprnd1, dw_val_class_decl_ref, dw_val_class_die_ref, dw_val_struct::dw_val_struct_union::dw_val_die_union::external, lookup_decl_die(), new_loc_descr(), dw_val_struct::v, dw_val_struct::val_class, dw_val_struct::dw_val_struct_union::val_decl_ref, and dw_val_struct::dw_val_struct_union::val_die_ref.
Referenced by mem_loc_descriptor().
|
static |
Referenced by break_out_includes().
|
static |
Close an include-file CU and reopen the enclosing one.
References die_struct::die_sib.
|
inlinestatic |
Pop a declaration scope.
Referenced by gen_struct_or_union_type_die(), gen_tagged_type_die(), and gen_type_die_for_member().
|
static |
POPCOUNT (const0 is DW_OP_lit0 or corresponding typed constant, const1 is DW_OP_lit1 or corresponding typed constant): const0 DW_OP_swap L1: DW_OP_dup DW_OP_bra <L2> DW_OP_dup DW_OP_rot const1 DW_OP_and DW_OP_plus DW_OP_swap const1 DW_OP_shr DW_OP_skip <L1> L2: DW_OP_drop PARITY is similar: L1: DW_OP_dup DW_OP_bra <L2> DW_OP_dup DW_OP_rot const1 DW_OP_and DW_OP_xor DW_OP_swap const1 DW_OP_shr DW_OP_skip <L1> L2: DW_OP_drop
References add_loc_descr(), dw_loc_descr_struct::dw_loc_oprnd1, dw_val_class_loc, mem_loc_descriptor(), new_loc_descr(), dw_val_struct::v, dw_val_struct::val_class, dw_val_struct::dw_val_struct_union::val_loc, and VAR_INIT_STATUS_INITIALIZED.
Referenced by mem_loc_descriptor().
|
static |
Mark all members of types_used_by_vars_entry as perennial.
References premark_types_used_by_global_vars_helper(), and types_used_by_vars_hash.
Referenced by prune_unused_types().
|
static |
Helper function of premark_types_used_by_global_vars which gets called through htab_traverse. Marks the DIE of a given type in *SLOT as perennial, so it never gets marked as unused by prune_unused_types. The DIE of the type is marked only if the global variable using the type will actually be emitted.
References symtab_node_base::definition, die_struct::die_parent, die_struct::die_perennial_p, lookup_type_die(), varpool_node::symbol, types_used_by_vars_entry::type, types_used_by_vars_entry::var_decl, and varpool_get_node().
Referenced by premark_types_used_by_global_vars().
|
static |
Mark all members of used_types_hash as perennial.
References premark_used_types_helper().
Referenced by gen_subprogram_die().
|
static |
Helper function of premark_used_types() which gets called through htab_traverse. Marks the DIE of a given type in *SLOT as perennial, so it never gets marked as unused by prune_unused_types.
References die_struct::die_perennial_p, lookup_type_die(), and type().
Referenced by premark_used_types().
|
static |
Referenced by debug(), debug_dwarf(), debug_dwarf_die(), and print_die().
|
static |
Print the information associated with a given DIE, and its children. This routine is a debugging aid only.
References AT_class(), AT_file(), AT_flag(), AT_int(), AT_lbl(), AT_loc_list(), AT_ref(), AT_string(), AT_unsigned(), AT_vms_delta1(), AT_vms_delta2(), die_struct::comdat_type_p, die_struct::die_abbrev, die_struct::die_attr, die_struct::die_child, die_struct::die_id, die_struct::die_mark, die_struct::die_offset, die_struct::die_tag, die_struct::die_symbol_or_type_node::die_type_node, dw_attr_struct::dw_attr, dw_attr_struct::dw_attr_val, dw_val_class_addr, dw_val_class_const, dw_val_class_const_double, dw_val_class_data8, dw_val_class_die_ref, dw_val_class_file, dw_val_class_flag, dw_val_class_high_pc, dw_val_class_lbl_id, dw_val_class_lineptr, dw_val_class_loc, dw_val_class_loc_list, dw_val_class_macptr, dw_val_class_offset, dw_val_class_range_list, dw_val_class_str, dw_val_class_unsigned_const, dw_val_class_vec, dw_val_class_vms_delta, dwarf_attr_name(), dwarf_tag_name(), double_int::high, HOST_WIDE_INT_PRINT_DEC, HOST_WIDE_INT_PRINT_UNSIGNED, double_int::low, print_die(), print_signature(), print_spaces(), comdat_type_struct::signature, dw_val_struct::v, dw_val_struct::dw_val_struct_union::val_data8, and dw_val_struct::dw_val_struct_union::val_double.
|
inlinestatic |
Print a type signature in hex.
Referenced by print_die().
|
static |
Referenced by print_die().
|
inlinestatic |
Indent the line the number of spaces given by print_indent.
|
static |
Process variable DECL (or variable with origin ORIGIN) within block STMT and add it to CONTEXT_DIE.
References add_child_die(), die_struct::die_parent, dwarf2out_imported_module_or_decl_1(), gen_decl_die(), lookup_decl_die(), and lookup_type_die().
Referenced by decls_for_scope().
|
static |
Referenced by prune_unmark_dies(), and prune_unused_types().
|
static |
Clear the marks for a die and its children. Be cool if the mark isn't set.
References die_struct::die_mark, and prune_unmark_dies().
|
static |
Remove dies representing declarations that we never use.
References comdat_type_list, comp_unit_die(), pubname_struct::die, limbo_die_struct::die, die_struct::die_tag, limbo_die_list, comdat_type_struct::next, limbo_die_struct::next, premark_types_used_by_global_vars(), prune_unmark_dies(), prune_unused_types_mark(), prune_unused_types_prune(), prune_unused_types_walk(), comdat_type_struct::root_die, comdat_type_struct::type_die, and verify_marks_clear().
Referenced by dwarf2out_finish().
|
static |
|
static |
Mark DIE as being used. If DOKIDS is true, then walk down to DIE's children.
References class_scope_p(), die_struct::die_definition, die_struct::die_mark, die_struct::die_parent, die_struct::die_tag, get_AT_flag(), is_declaration_die(), is_type_die(), prune_unused_types_mark(), prune_unused_types_mark_generic_parms_dies(), prune_unused_types_walk(), and prune_unused_types_walk_attribs().
|
static |
Referenced by prune_unused_types_mark().
|
static |
Mark the generic parameters and arguments children DIEs of DIE.
References die_struct::die_child, die_struct::die_sib, is_template_parameter(), and prune_unused_types_mark().
|
static |
Referenced by prune_unused_types(), and prune_unused_types_prune().
|
static |
Remove from the tree DIE any dies that aren't marked.
References die_struct::die_child, die_struct::die_mark, die_struct::die_sib, prune_unused_types_prune(), and prune_unused_types_update_strings().
|
static |
Increment the string counts on strings referred to from DIE's attributes.
References AT_class(), die_struct::die_attr, dw_attr_struct::dw_attr_val, dw_val_class_str, indirect_string_node::refcount, indirect_string_node::str, dw_val_struct::v, and dw_val_struct::dw_val_struct_union::val_str.
Referenced by prune_unused_types_prune().
|
static |
Referenced by prune_unused_types(), prune_unused_types_mark(), and prune_unused_types_walk().
|
static |
Walk the tree DIE and mark types that we actually use.
References die_struct::die_mark, die_struct::die_parent, die_struct::die_perennial_p, die_struct::die_tag, prune_unused_types_walk(), prune_unused_types_walk_attribs(), and prune_unused_types_walk_local_classes().
|
static |
Referenced by prune_unused_types_mark(), and prune_unused_types_walk().
|
static |
Given DIE that we're marking as used, find any other dies it references as attributes and mark them as used.
References AT_class(), AT_ref(), dw_val_struct::dw_val_struct_union::dw_val_die_union::die, die_struct::die_attr, dw_attr_struct::dw_attr, dw_attr_struct::dw_attr_val, dw_val_class_die_ref, dw_val_class_str, prune_unused_types_mark(), indirect_string_node::refcount, dw_val_struct::v, dw_val_struct::val_class, dw_val_struct::dw_val_struct_union::val_die_ref, and dw_val_struct::dw_val_struct_union::val_str.
|
static |
For local classes, look if any static member functions were emitted and if so, mark them.
References die_struct::die_definition, die_struct::die_mark, die_struct::die_tag, get_AT_flag(), and prune_unused_types_mark().
Referenced by prune_unused_types_walk().
|
static |
Referenced by gen_struct_or_union_type_die(), gen_tagged_type_die(), and gen_type_die_for_member().
|
static |
Push a new declaration scope.
References vec_safe_push().
|
static |
Add OPCODE+VAL as an entry at the end of the opcode array in TABLE.
References dw_line_info_table_struct::entries, dw_line_info_struct::opcode, dw_line_info_struct::val, and vec_safe_push().
Referenced by dwarf2out_source_line().
|
static |
Referenced by break_out_includes().
|
static |
Start a new compilation unit DIE for an include file. OLD_UNIT is the CU for the enclosing include file, if any. BINCL_DIE is the DW_TAG_GNU_BINCL DIE that marks the start of the DIEs for this include file.
References die_struct::die_sib, gen_compile_unit_die(), and get_AT_string().
|
static |
Record SYM_NUM to record of CU in HTABLE.
References die_struct::die_id, die_struct::die_symbol_or_type_node::die_symbol, hash_table< Descriptor, Allocator >::find_slot_with_hash(), and cu_hash_table_entry::max_comdat_num.
Referenced by break_out_includes().
|
static |
Determine what tag to use for a record type.
References lang_hooks_for_types::classify_record, RECORD_IS_CLASS, RECORD_IS_INTERFACE, RECORD_IS_STRUCT, and lang_hooks::types.
Referenced by gen_struct_or_union_type_die().
Determine whether the evaluation of EXPR references any variables or functions which aren't otherwise used (and therefore may not be output).
References cgraph_get_node(), cgraph_global_info_ready, symtab_node_base::definition, varpool_node::symbol, and varpool_get_node().
Referenced by rtl_for_decl_init().
|
static |
Referenced by gen_subprogram_die(), and loc_descriptor().
|
static |
Return a location descriptor that designates a machine register or zero if there is none.
References add_loc_descr(), dbx_reg_number(), eliminate_regs(), mem_loc_descriptor(), multiple_reg_loc_descriptor(), new_loc_descr(), one_reg_loc_descriptor(), and targetm.
|
static |
Referenced by remove_loc_list_addr_table_entries(), and resolve_addr().
|
static |
Remove an entry from the addr table by decrementing its refcount. Strictly, decrementing the refcount would be enough, but the assertion that the entry is actually in the table has found bugs.
References addr_index_table, addr_table_entry_struct::index, and addr_table_entry_struct::refcount.
|
static |
|
static |
Remove the specified attribute if present.
References AT_class(), die_struct::die_attr, dw_attr_struct::dw_attr, dw_attr_struct::dw_attr_val, dw_val_class_str, indirect_string_node::refcount, dw_val_struct::v, and dw_val_struct::dw_val_struct_union::val_str.
|
static |
Remove the CHILD DIE from its parent, possibly replacing it with a cloned declaration. The original DIE is moved to a new compile unit so that existing references to it follow it to the new location. If any of the original DIE's descendants is a declaration, we need to replace the original DIE with a skeleton tree and move the declarations back into the skeleton tree.
References add_child_die(), die_struct::comdat_type_p, copy_declaration_context(), die_struct::die_id, die_struct::die_symbol_or_type_node::die_type_node, generate_skeleton(), remove_child_with_prev(), and replace_child().
Referenced by break_out_comdat_types().
|
static |
Referenced by gen_subprogram_die().
|
static |
Remove child DIE whose die_tag is TAG. Do nothing if no child matches TAG.
References die_struct::die_child, die_struct::die_sib, die_struct::die_tag, and remove_child_with_prev().
|
static |
Remove CHILD from its parent. PREV must have the property that PREV->DIE_SIB == CHILD. Does not alter CHILD.
References die_struct::die_child, die_struct::die_parent, and die_struct::die_sib.
Referenced by break_out_includes(), generate_skeleton_bottom_up(), move_marked_base_types(), remove_child_or_replace_with_skeleton(), remove_child_TAG(), and splice_child_die().
|
static |
Given a location list, remove all addresses it refers to from the address_table.
References dw_loc_descr_struct::dw_loc_next, dw_loc_descr_struct::dw_loc_oprnd1, addr_table_entry_struct::index, remove_addr_table_entry(), and dw_val_struct::val_entry.
Referenced by resolve_addr().
|
static |
Replace OLD_CHILD with NEW_CHILD. PREV must have the property that PREV->DIE_SIB == OLD_CHILD. Does not alter OLD_CHILD.
References die_struct::die_child, die_struct::die_parent, and die_struct::die_sib.
Referenced by generate_skeleton_bottom_up(), and remove_child_or_replace_with_skeleton().
|
static |
Resolve DW_OP_addr and DW_AT_const_value CONST_STRING arguments to an address in .rodata section if the string literal is emitted there, or remove the containing location list or replace DW_AT_const_value with DW_AT_location and empty location expression, if it isn't found in .rodata. Similarly for SYMBOL_REFs, keep only those that refer to something that has been emitted in the current CU.
References AT_class(), AT_index(), AT_loc(), AT_loc_list_ptr(), dw_val_struct::dw_val_struct_union::dw_val_die_union::die, die_struct::die_attr, die_struct::die_tag, dw_attr_struct::dw_attr, dw_attr_struct::dw_attr_val, dw_loc_descr_struct::dw_loc_next, dw_loc_list_struct::dw_loc_next, dw_loc_descr_struct::dw_loc_oprnd1, dw_val_class_addr, dw_val_class_die_ref, dw_val_class_loc, dw_val_class_loc_list, dw_val_struct::dw_val_struct_union::dw_val_die_union::external, force_decl_die(), dw_loc_list_struct::ll_symbol, lookup_decl_die(), mark_base_types(), optimize_location_into_implicit_ptr(), remove_addr_table_entry(), remove_AT(), remove_loc_list_addr_table_entries(), dw_loc_list_struct::replaced, resolve_addr_in_expr(), resolve_one_addr(), dw_loc_list_struct::resolved_addr, dw_val_struct::v, dw_val_struct::dw_val_struct_union::val_addr, dw_val_struct::val_class, dw_val_struct::dw_val_struct_union::val_die_ref, and dw_val_struct::val_entry.
Referenced by dwarf2out_finish().
|
static |
Helper function for resolve_addr, handle one location expression, return false if at least one CONST_STRING or SYMBOL_REF in the location list couldn't be resolved.
References add_loc_descr(), die_struct::die_tag, dw_val_class_addr, dw_val_class_decl_ref, dw_val_class_die_ref, dw_val_class_unsigned_const, get_AT_unsigned(), int_loc_descriptor(), lookup_decl_die(), new_loc_descr(), optimize_one_addr_into_implicit_ptr(), resolve_one_addr(), size_of_int_loc_descriptor(), and size_of_loc_descr().
Referenced by resolve_addr().
|
static |
Referenced by add_const_value_attribute(), mem_loc_descriptor(), resolve_addr(), resolve_addr_in_expr(), and resolve_one_addr().
|
static |
Helper function for resolve_addr, attempt to resolve one CONST_STRING, return non-zero if not successful. Similarly verify that SYMBOL_REFs refer to variables emitted in the current CU.
References build_array_type(), build_index_type(), build_string(), for_each_rtx(), len, lookup_constant_def(), resolve_one_addr(), strlen(), and vec_safe_push().
|
static |
Walk through the list of incomplete types again, trying once more to emit full debugging info for them.
References comp_unit_die(), DINFO_USAGE_DIR_USE, gen_type_die(), should_emit_struct_debug(), and vec_safe_length().
Referenced by dwarf2out_finish().
|
static |
ROTATE (constMASK is mode mask, BITSIZE is bitsize of mode): DW_OP_over DW_OP_over DW_OP_shl [ constMASK DW_OP_and ] DW_OP_rot [ DW_OP_swap constMASK DW_OP_and DW_OP_swap ] DW_OP_neg DW_OP_plus_uconst <BITSIZE> DW_OP_shr DW_OP_or ROTATERT is similar: DW_OP_over DW_OP_over DW_OP_neg DW_OP_plus_uconst <BITSIZE> DW_OP_shl [ constMASK DW_OP_and ] DW_OP_rot [ DW_OP_swap constMASK DW_OP_and DW_OP_swap ] DW_OP_shr DW_OP_or
References add_loc_descr(), HOST_BITS_PER_WIDE_INT, mem_loc_descriptor(), new_loc_descr(), and VAR_INIT_STATUS_INITIALIZED.
Referenced by mem_loc_descriptor().
|
inlinestatic |
Return the result of rounding T up to ALIGN.
References double_int::div(), and double_int::from_uhwi().
Referenced by field_byte_offset().
|
static |
Generate an RTL constant from a decl initializer INIT with decl type TYPE, for use in a later add_const_value_attribute call.
References build_vector_from_ctor(), compare_tree_int(), expand_expr(), EXPAND_INITIALIZER, gen_rtx_MEM(), initializer_constant_valid_p(), integer_zerop(), reference_to_unused(), and strlen().
Referenced by rtl_for_decl_location(), and tree_add_const_value_attribute().
Referenced by add_location_or_const_value_attribute(), and loc_list_from_tree().
|
static |
Generate RTL for the variable DECL to represent its location.
References avoid_constant_pool_reference(), gen_rtx_MEM(), get_address_mode(), is_pseudo_reg(), make_decl_rtl_for_debug(), offset, plus_constant(), reload_completed, rtl_for_decl_init(), and targetm.
|
static |
Referenced by same_die_p().
|
static |
Do the attributes look the same?
References dw_attr_struct::dw_attr, dw_attr_struct::dw_attr_val, and same_dw_val_p().
|
static |
Referenced by same_die_p(), same_die_p_wrap(), and same_dw_val_p().
|
static |
Do the dies look the same?
References die_struct::die_attr, die_struct::die_child, die_struct::die_mark, die_struct::die_sib, die_struct::die_tag, same_attr_p(), same_die_p(), and vec_safe_length().
|
static |
Referenced by check_duplicate_cu().
|
static |
Do the dies look the same? Wrapper around same_die_p.
References same_die_p(), and unmark_all_dies().
|
static |
Referenced by same_attr_p(), and same_loc_p().
|
static |
Do the values look the same?
References dw_vec_struct::array, dw_val_struct::dw_val_struct_union::dw_val_die_union::die, dw_loc_descr_struct::dw_loc_next, dw_val_class_addr, dw_val_class_const, dw_val_class_const_double, dw_val_class_data8, dw_val_class_die_ref, dw_val_class_fde_ref, dw_val_class_file, dw_val_class_flag, dw_val_class_high_pc, dw_val_class_lbl_id, dw_val_class_lineptr, dw_val_class_loc, dw_val_class_macptr, dw_val_class_offset, dw_val_class_str, dw_val_class_unsigned_const, dw_val_class_vec, dw_val_class_vms_delta, dw_vec_struct::elt_size, double_int::high, dw_vec_struct::length, double_int::low, rtx_equal_p(), same_die_p(), same_loc_p(), indirect_string_node::str, dw_val_struct::v, dw_val_struct::dw_val_struct_union::val_addr, dw_val_struct::val_class, dw_val_struct::dw_val_struct_union::val_data8, dw_val_struct::dw_val_struct_union::val_die_ref, dw_val_struct::dw_val_struct_union::val_double, dw_val_struct::dw_val_struct_union::val_file, dw_val_struct::dw_val_struct_union::val_flag, dw_val_struct::dw_val_struct_union::val_int, dw_val_struct::dw_val_struct_union::val_loc, dw_val_struct::dw_val_struct_union::val_offset, dw_val_struct::dw_val_struct_union::val_str, dw_val_struct::dw_val_struct_union::val_unsigned, and dw_val_struct::dw_val_struct_union::val_vec.
|
static |
Referenced by same_dw_val_p().
|
inlinestatic |
Do the location expressions look same?
References dw_loc_descr_struct::dw_loc_oprnd1, dw_loc_descr_struct::dw_loc_oprnd2, and same_dw_val_p().
|
static |
Save any strings needed by the macinfo table in the debug str table. All strings must be collected into the table by the time index_string is called.
References macinfo_struct::code, find_AT_string(), macinfo_struct::info, len, set_indirect_string(), and strlen().
Referenced by dwarf2out_finish().
|
static |
Referenced by gen_struct_or_union_type_die().
|
static |
Schedule the generation of the generic parameter dies for the instance of generic type T. The proper generation itself is later done by gen_scheduled_generic_parms_dies.
References generic_type_p(), vec_alloc(), and vec_safe_push().
|
static |
Return location descriptor for signed comparison OP RTL.
References add_loc_descr(), base_type_for_mode(), compare_loc_descriptor(), dw_val_struct::dw_val_struct_union::dw_val_die_union::die, dw_loc_descr_struct::dw_loc_next, dw_loc_descr_struct::dw_loc_oprnd1, dw_val_class_die_ref, dw_val_struct::dw_val_struct_union::dw_val_die_union::external, HOST_BITS_PER_WIDE_INT, HOST_WIDE_INT, int_loc_descriptor(), mem_loc_descriptor(), new_loc_descr(), shift, size_of_int_loc_descriptor(), dw_val_struct::v, dw_val_struct::val_class, dw_val_struct::dw_val_struct_union::val_die_ref, dw_val_struct::dw_val_struct_union::val_int, and VAR_INIT_STATUS_INITIALIZED.
Referenced by mem_loc_descriptor().
|
static |
|
static |
Return the DIE for the scope that immediately contains this type. Non-named types that do not involve a function-local type get global scope. Named types nested in namespaces or other types get their containing scope. All other types (i.e. function-local named types) get the current active scope.
References comp_unit_die(), current_function_decl, DINFO_LEVEL_TERSE, get_context_die(), lookup_decl_die(), lookup_type_die_strip_naming_typedef(), and uses_local_type().
|
static |
We need to figure out what section we should use as the base for the address ranges where a given location is valid. 1. If this particular DECL has a section associated with it, use that. 2. If this function has a section associated with it, use that. 3. Otherwise, use the text section. XXX: If you split a variable across multiple sections, we won't notice.
References cfun, current_function_decl, in_cold_section_p, and text_section_label.
Referenced by convert_cfa_to_fb_loc_list(), and dw_loc_list().
|
inlinestatic |
Referenced by build_abbrev_table().
|
inlinestatic |
|
static |
Given a pointer to some BLOCK node, and a boolean value to set the "abstract" flags to, set that value into the BLOCK_ABSTRACT flag for the given block, and for all local decls and all local sub-blocks (recursively) which are contained therein.
References set_decl_abstract_flags().
Referenced by set_decl_abstract_flags().
|
static |
Given a pointer to some BLOCK node, if the BLOCK_ABSTRACT_ORIGIN for the given BLOCK node is NULL, set the BLOCK_ABSTRACT_ORIGIN for the node so that it points to the node itself, thus indicating that the node is its own (abstract) origin. Additionally, if the BLOCK_ABSTRACT_ORIGIN for the given node is NULL, recursively descend the decl/block tree which it is the root of, and for each other ..._DECL or BLOCK node contained therein whose DECL_ABSTRACT_ORIGINs or BLOCK_ABSTRACT_ORIGINs are also still NULL, set *their* DECL_ABSTRACT_ORIGIN or BLOCK_ABSTRACT_ORIGIN values to point to themselves.
References set_decl_origin_self().
Referenced by set_decl_origin_self().
|
static |
Referenced by dwarf2out_begin_function(), and dwarf2out_switch_text_section().
|
static |
Lookup the "current" table into which we emit line info, so that we don't have to do it for every source line.
References cold_end_label, cold_text_section_line_info, dw_line_info_table_struct::end_label, in_cold_section_p, dw_line_info_table_struct::is_stmt, new_line_info_table(), table, text_section, text_section_line_info, and vec_safe_push().
|
static |
Referenced by dwarf2out_abstract_function(), and set_block_abstract_flags().
|
static |
Given a pointer to some ..._DECL node, and a boolean value to set the "abstract" flags to, set that value into the DECL_ABSTRACT flag for the given decl, and (in the case where the decl is a FUNCTION_DECL) also set the abstract flags for all of the parameters, local vars, local blocks and sub-blocks (recursively) to the same setting.
References set_block_abstract_flags().
|
static |
Forward declare these functions, because they are mutually recursive with their set_block_* pairing functions.
Referenced by gen_decl_die(), and set_block_origin_self().
|
static |
Given a pointer to some ..._DECL node, if the DECL_ABSTRACT_ORIGIN for the given ..._DECL node is NULL, set the DECL_ABSTRACT_ORIGIN for the node to so that it points to the node itself, thus indicating that the node represents its own (abstract) origin. Additionally, if the DECL_ABSTRACT_ORIGIN for the given node is NULL, recursively descend the decl/block tree of which the given node is the root of, and for each other ..._DECL or BLOCK node contained therein whose DECL_ABSTRACT_ORIGINs or BLOCK_ABSTRACT_ORIGINs are also still NULL, set *their* DECL_ABSTRACT_ORIGIN or BLOCK_ABSTRACT_ORIGIN values to point to themselves.
References set_block_origin_self().
|
static |
Call this function directly to bypass AT_string_form's logic to put the string inline in the die.
References dw2_string_counter, indirect_string_node::form, indirect_string_node::index, and indirect_string_node::label.
Referenced by find_string_form(), and save_macinfo_strings().
|
static |
Referenced by declare_in_namespace(), and gen_namespace_die().
|
static |
Force out any required namespaces to be able to output DECL, and return the new context_die for it, if it's changed.
References force_decl_die().
|
static |
References DINFO_STRUCT_FILE_ANY, DINFO_STRUCT_FILE_NONE, DINFO_STRUCT_FILE_SYS, lang_hooks_for_types::generic_p, matches_main_base(), lang_hooks::types, and usage().
Referenced by dwarf2out_imported_module_or_decl(), dwarf2out_imported_module_or_decl_1(), gen_struct_or_union_type_die(), and retry_incomplete_types().
|
static |
Referenced by break_out_comdat_types().
|
static |
Return non-zero if this is a type DIE that should be moved to a COMDAT .debug_types section.
References contains_subprogram_definition(), die_struct::die_tag, get_AT(), is_declaration_die(), and is_nested_in_subprogram().
|
static |
Referenced by field_byte_offset().
|
inlinestatic |
|
static |
Referenced by field_byte_offset().
|
inlinestatic |
Given a pointer to a tree node, return the alignment in bits for it, or else return BITS_PER_WORD if the node actually turns out to be an ERROR_MARK node.
|
static |
|
inlinestatic |
Given a pointer to a tree node, assumed to be some kind of a ..._TYPE node, return the size in bits for the type if it is a constant, or else return the alignment for the type if the type's size is not constant, or else return BITS_PER_WORD if the type actually turns out to be an ERROR_MARK node.
References host_integerp(), and tree_low_cst().
|
static |
Return if the loc_list has only single element and thus can be represented as location description.
References dw_loc_list_struct::dw_loc_next, and dw_loc_list_struct::ll_symbol.
Referenced by add_AT_location_description(), add_bound_info(), and gen_variable_die().
|
static |
Return the size of the information in the .debug_aranges section.
References cold_text_section_used, dw_fde_struct::decl, dw_fde_struct::dw_fde_second_begin, fde_vec, have_multiple_function_sections, dw_fde_struct::in_std_section, dw_fde_struct::second_in_std_section, and text_section_used.
Referenced by dwarf2out_finish().
|
static |
Referenced by calc_base_type_die_sizes(), calc_die_sizes(), output_comdat_type_unit(), and output_skeleton_debug_sections().
|
static |
Return the size of a DIE as it is represented in the .debug_info section.
References AT_class(), AT_index(), AT_int(), AT_loc(), AT_ref_external(), AT_string_form(), AT_unsigned(), constant_size(), die_struct::die_abbrev, die_struct::die_attr, dw_attr_struct::dw_attr, dw_attr_struct::dw_attr_val, dw_val_class_addr, dw_val_class_const, dw_val_class_const_double, dw_val_class_data8, dw_val_class_die_ref, dw_val_class_fde_ref, dw_val_class_file, dw_val_class_flag, dw_val_class_high_pc, dw_val_class_lbl_id, dw_val_class_lineptr, dw_val_class_loc, dw_val_class_loc_list, dw_val_class_macptr, dw_val_class_offset, dw_val_class_range_list, dw_val_class_str, dw_val_class_unsigned_const, dw_val_class_vec, dw_val_class_vms_delta, dw_vec_struct::elt_size, HOST_BITS_PER_CHAR, HOST_BITS_PER_WIDE_INT, dw_vec_struct::length, maybe_emit_file(), size_of_locs(), size_of_sleb128(), size_of_uleb128(), indirect_string_node::str, strlen(), dw_val_struct::v, dw_val_struct::dw_val_struct_union::val_file, dw_val_struct::dw_val_struct_union::val_flag, dw_val_struct::dw_val_struct_union::val_str, and dw_val_struct::dw_val_struct_union::val_vec.
|
static |
|
static |
Return size_of_locs (int_loc_descriptor (i)) without actually allocating it.
References clz_hwi(), ctz_hwi(), HOST_BITS_PER_WIDE_INT, size_of_int_loc_descriptor(), size_of_int_shift_loc_descriptor(), size_of_sleb128(), and size_of_uleb128().
|
static |
Return size_of_locs (int_shift_loc_descriptor (i, shift)) without actually allocating it.
References size_of_int_loc_descriptor().
Referenced by size_of_int_loc_descriptor().
|
static |
Return the size of a location descriptor.
References dw_val_struct::dw_val_struct_union::dw_val_die_union::die, dw_loc_descr_struct::dw_loc_oprnd1, dw_loc_descr_struct::dw_loc_oprnd2, dw_val_class_const, dw_val_class_const_double, dw_val_class_unsigned_const, dw_val_class_vec, dw_vec_struct::elt_size, get_base_type_offset(), HOST_BITS_PER_WIDE_INT, addr_table_entry_struct::index, dw_vec_struct::length, size_of_locs(), size_of_sleb128(), size_of_uleb128(), dw_val_struct::v, dw_val_struct::val_class, dw_val_struct::dw_val_struct_union::val_die_ref, dw_val_struct::val_entry, dw_val_struct::dw_val_struct_union::val_int, dw_val_struct::dw_val_struct_union::val_loc, dw_val_struct::dw_val_struct_union::val_unsigned, and dw_val_struct::dw_val_struct_union::val_vec.
Referenced by resolve_addr_in_expr(), and size_of_locs().
unsigned long size_of_locs | ( | ) |
Return the size of a series of location descriptors.
References dw_loc_descr_struct::dw_loc_addr, dw_loc_descr_struct::dw_loc_next, and size_of_loc_descr().
Referenced by hash_locs(), output_cfa_loc(), output_cfa_loc_raw(), output_die(), output_loc_list(), output_loc_operands(), size_of_die(), size_of_loc_descr(), and value_format().
|
static |
Referenced by output_pubnames().
|
static |
Return the size of the .debug_pubnames or .debug_pubtypes table generated for the compilation unit.
References include_pubname_in_output(), pubname_struct::name, and strlen().
|
static |
Referenced by gen_member_die().
|
static |
Move CHILD, which must be a child of PARENT or the DIE for which PARENT is the specification, to the end of PARENT's list of children. This is done by removing and re-adding it.
References add_child_die(), die_struct::die_child, die_struct::die_parent, die_struct::die_sib, get_AT_ref(), and remove_child_with_prev().
|
static |
For STRING_CST, return SYMBOL_REF of its constant pool entry, if possible, and create DW_TAG_dwarf_procedure that can be referenced from DW_OP_GNU_implicit_pointer if the string hasn't been seen yet.
References add_AT_loc(), dw_vec_struct::array, comp_unit_die(), dw_loc_descr_struct::dw_loc_oprnd2, dw_val_class_vec, dw_vec_struct::elt_size, equate_decl_number_to_die(), len, dw_vec_struct::length, lookup_decl_die(), memcpy(), new_die(), new_loc_descr(), output_constant_def(), dw_val_struct::v, dw_val_struct::val_class, dw_val_struct::dw_val_struct_union::val_vec, and vec_safe_push().
Referenced by optimize_location_into_implicit_ptr(), and optimize_one_addr_into_implicit_ptr().
|
static |
Referenced by get_context_die(), and lookup_type_die_strip_naming_typedef().
|
inlinestatic |
Given a TYPE_DIE representing the type TYPE, if TYPE is an anonymous type named by the typedef TYPE_DIE, return the DIE of the anonymous type instead the one of the naming typedef.
References die_struct::die_tag, get_AT_ref(), and is_naming_typedef_decl().
|
static |
Forward declarations for functions defined in this file.
|
inlinestatic |
Return a pointer to a copy of the section string name S with all attributes stripped off, and an asterisk prepended (for assemble_name).
References strlen().
|
static |
Referenced by modified_type_die().
|
static |
Given a pointer to a tree node for a subrange type, return a pointer to a DIE that describes the given type.
References add_AT_unsigned(), add_bound_info(), comp_unit_die(), int_size_in_bytes(), new_die(), and size_in_bytes().
|
static |
Switch [BACK] to eh_frame_section. If we don't have an eh_frame_section, switch to the data section instead, and write out a synthetic start label for collect2 the first time around.
References asm_out_file, data_section, eh_frame_section, floor_log2(), get_file_function_name(), get_section(), switch_to_section(), and targetm.
Referenced by switch_to_frame_table_section().
|
static |
Switch [BACK] to the eh or debug frame table section, depending on FOR_EH.
References get_section(), switch_to_eh_frame_section(), and switch_to_section().
Referenced by output_call_frame_info(), and output_fde().
|
static |
Generate and return a DW_TAG_GNU_template_parameter_pack DIE representing. PARM_PACK must be a template parameter pack. The returned DIE will be child DIE of PARENT_DIE.
References add_name_and_src_coords_attributes(), generic_parameter_die(), and new_die().
Referenced by gen_generic_params_dies().
|
static |
Try to handle TLS MEMs, for which mem_loc_descriptor on XEXP (mem, 0) failed.
References get_base_address(), loc_descr_plus_const(), and loc_descriptor_from_tree().
Referenced by loc_descriptor(), and mem_loc_descriptor().
|
static |
|
static |
Attach a DW_AT_const_value attribute to DIE. The value of the attribute is the const value T.
References add_AT_vec(), add_const_value_attribute(), ggc_free(), initializer_constant_valid_p(), int_size_in_bytes(), native_encode_initializer(), and rtl_for_decl_init().
|
static |
Referenced by add_location_or_const_value_attribute(), gen_const_die(), and gen_variable_die().
|
static |
Attach a DW_AT_const_value attribute to VAR_DIE. The value of the attribute is the const value of T, where T is an integral constant variable with static storage duration (so it can't be a PARM_DECL or a RESULT_DECL).
References get_AT(), and tree_add_const_value_attribute().
|
static |
|
inlinestatic |
Given a pointer to an arbitrary ..._TYPE tree node, return true if it is an enumerated type.
Referenced by gen_type_die_with_usage(), and modified_type_die().
|
inlinestatic |
Return a reference to a type, with its const and volatile qualifiers removed.
References type().
|
static |
|
static |
Given a tree pointer to a struct, class, union, or enum type node, return a pointer to the (string) tag name for the given type, or zero if the type was declared without a tag.
References lang_hooks::dwarf_name.
|
static |
Helper function for mem_loc_descriptor. Perform OP binary op, but after converting arguments to type_die, afterwards convert back to unsigned.
References add_loc_descr(), convert_descriptor_to_mode(), dw_val_struct::dw_val_struct_union::dw_val_die_union::die, dw_loc_descr_struct::dw_loc_oprnd1, dw_val_class_die_ref, dw_val_struct::dw_val_struct_union::dw_val_die_union::external, mem_loc_descriptor(), new_loc_descr(), dw_val_struct::v, dw_val_struct::val_class, dw_val_struct::dw_val_struct_union::val_die_ref, and VAR_INIT_STATUS_INITIALIZED.
Referenced by mem_loc_descriptor().
|
static |
Return location descriptor for unsigned comparison OP RTL.
References add_loc_descr(), compare_loc_descriptor(), dw_loc_descr_struct::dw_loc_next, dw_loc_descr_struct::dw_loc_oprnd1, int_loc_descriptor(), mem_loc_descriptor(), new_loc_descr(), dw_val_struct::v, dw_val_struct::dw_val_struct_union::val_int, and VAR_INIT_STATUS_INITIALIZED.
Referenced by mem_loc_descriptor().
|
static |
Referenced by compute_section_prefix(), dwarf2out_finish(), generate_type_signature(), same_die_p_wrap(), and unmark_all_dies().
|
static |
Clear the marks for a die, its children and referred dies.
References AT_class(), AT_ref(), die_struct::die_attr, die_struct::die_mark, dw_val_class_die_ref, and unmark_all_dies().
|
static |
Referenced by copy_decls_for_unworthy_types(), output_comdat_type_unit(), output_comp_unit(), and unmark_dies().
|
static |
Clear the marks for a die and its children.
References die_struct::die_mark, and unmark_dies().
|
static |
If TYPE involves a function-local type (including a local typedef to a non-local type), returns that type; otherwise returns NULL_TREE.
References uses_local_type_r().
Referenced by scope_die_for().
|
static |
walk_tree helper function for uses_local_type, below.
References decl_function_context().
Referenced by uses_local_type().
|
static |
Referenced by build_abbrev_table(), and output_value_format().
|
static |
Select the encoding of an attribute value.
References AT_class(), AT_index(), AT_loc(), AT_ref_external(), AT_string_form(), AT_unsigned(), constant_size(), dw_attr_struct::dw_attr, dw_attr_struct::dw_attr_val, dw_val_class_addr, dw_val_class_const, dw_val_class_const_double, dw_val_class_data8, dw_val_class_die_ref, dw_val_class_fde_ref, dw_val_class_file, dw_val_class_flag, dw_val_class_high_pc, dw_val_class_lbl_id, dw_val_class_lineptr, dw_val_class_loc, dw_val_class_loc_list, dw_val_class_macptr, dw_val_class_offset, dw_val_class_range_list, dw_val_class_str, dw_val_class_unsigned_const, dw_val_class_vec, dw_val_class_vms_delta, dw_vec_struct::elt_size, HOST_BITS_PER_WIDE_INT, dw_vec_struct::length, maybe_emit_file(), size_of_locs(), dw_val_struct::v, dw_val_struct::dw_val_struct_union::val_file, dw_val_struct::dw_val_struct_union::val_flag, and dw_val_struct::dw_val_struct_union::val_vec.
|
static |
Note in all location lists that text section has changed.
References decl_loc_table, and var_location_switch_text_section_1().
Referenced by dwarf2out_switch_text_section().
|
static |
Note in one location list that text section has changed.
References var_loc_list_def::first, var_loc_list_def::last, var_loc_list_def::last_before_switch, and var_loc_node::next.
Referenced by var_location_switch_text_section().
|
static |
Verify that all marks are clear.
References die_struct::die_mark.
Referenced by prune_unused_types().
int vms_file_stats_name | ( | const char * | , |
long long * | , | ||
long * | , | ||
char * | , | ||
int * | |||
) |
Return VMS file date, size, format, version given a name.
References vstring::length, memset(), IOSB::status, vstring::string, strlen(), to_vms_file_spec(), and tryfile.
Referenced by lookup_filename(), and output_file_names().
|
inlinestatic |
Whether to generate the DWARF accelerator tables in .debug_pubnames and .debug_pubtypes. This is configured per-target, but can be overridden by the -gpubnames or -gno-pubnames options.
References targetm.
Referenced by add_AT_pubnames(), add_pubname(), add_pubtype(), gen_namespace_die(), gen_subprogram_die(), gen_variable_die(), and output_pubnames().
|
static |
A pointer to the base of a list of references to DIE's that are uniquely identified by their tag, presence/absence of children DIE's, and list of attribute/value pairs.
|
static |
Number of elements currently allocated for abbrev_die_table.
|
static |
Number of elements in type_die_table currently in use.
Referenced by build_abbrev_table(), and output_abbrev_section().
|
static |
|
static |
Table of entries into the .debug_addr section.
Referenced by add_addr_table_entry(), dwarf2out_finish(), output_addr_table(), and remove_addr_table_entry().
|
static |
|
static |
Vector mapping block numbers to DW_TAG_{lexical_block,inlined_subroutine} DIEs.
Referenced by dwarf2out_function_decl(), gen_call_site_die(), gen_inlined_subroutine_die(), and gen_lexical_block_die().
|
static |
Table of cached location lists.
Referenced by dwarf2out_abstract_function().
|
static |
Referenced by dwarf2out_end_epilogue(), and dwarf2out_var_location().
|
static |
Referenced by dwarf2out_function_decl(), dwarf2out_var_location(), and gen_subprogram_die().
|
static |
Head and tail of call_arg_loc chain.
Referenced by dwarf2out_abstract_function(), dwarf2out_function_decl(), dwarf2out_var_location(), gen_inlined_subroutine_die(), gen_lexical_block_die(), and gen_subprogram_die().
|
static |
Number of call sites in the current function.
Referenced by dwarf2out_abstract_function(), dwarf2out_begin_function(), dwarf2out_function_decl(), dwarf2out_var_location(), and gen_subprogram_die().
|
static |
Referenced by set_cur_line_info_table().
|
static |
The default cold text section.
Referenced by dwarf2out_begin_prologue(), and dwarf2out_switch_text_section().
|
static |
|
static |
Referenced by set_cur_line_info_table().
|
static |
Referenced by dwarf2out_finish(), dwarf2out_note_section_used(), output_aranges(), and size_of_aranges().
|
static |
The prefix to attach to symbols on DIEs in the current comdat debug info section.
|
static |
The index of the current symbol within the current comdat CU.
|
static |
A list of type DIEs that have been separated into comdat sections.
Referenced by break_out_comdat_types(), dwarf2out_finish(), and prune_unused_types().
|
static |
A hash table of references to DIE's that describe COMMON blocks. The key is DECL_UID() ^ die_parent.
Referenced by gen_variable_die().
|
static |
The current table to which we should emit line number information for the current function. This will be set up at the beginning of assembly for the function.
Referenced by dwarf2out_source_line().
|
static |
Record whether the function being analyzed contains inlined functions.
|
static |
Personality decl of current unit. Used only when assembler does not support personality CFI.
Referenced by output_call_frame_info().
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
Pointers to various DWARF2 sections.
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
A hash table of references to DIE's that describe declarations. The key is a DECL_UID() which is a unique number identifying each decl.
Referenced by dwarf2out_init(), equate_decl_number_to_die(), and lookup_decl_die().
|
static |
Table of decl location linked lists.
Referenced by add_var_loc_to_decl(), dwarf2out_abstract_function(), dwarf2out_end_function(), dwarf2out_function_decl(), dwarf2out_init(), lookup_decl_loc(), and var_location_switch_text_section().
A pointer to the base of a table of references to declaration scopes. This table is a display which tracks the nesting of declaration scopes at the current scope and containing scopes. This table is used to find the proper place to define type declaration DIE's.
|
static |
A list of DIEs for which we may have to generate DW_AT_{,MIPS_}linkage_name once their DECL_ASSEMBLER_NAMEs are set.
Referenced by add_linkage_name(), and dwarf2out_finish().
|
static |
Referenced by defer_location(), and dwarf2out_finish().
|
static |
We allow a language front-end to designate a function that is to be called to "demangle" any name before it is put into a DIE.
Referenced by add_name_attribute(), and dwarf2out_set_demangle_name_func().
|
static |
Referenced by set_indirect_string().
struct gcc_debug_hooks dwarf2_debug_hooks |
The debug hooks structure.
Referenced by process_options(), vmsdbgout_abstract_function(), vmsdbgout_assembly_start(), vmsdbgout_begin_block(), vmsdbgout_begin_epilogue(), vmsdbgout_begin_function(), vmsdbgout_begin_prologue(), vmsdbgout_decl(), vmsdbgout_define(), vmsdbgout_end_block(), vmsdbgout_end_epilogue(), vmsdbgout_end_function(), vmsdbgout_end_prologue(), vmsdbgout_end_source_file(), vmsdbgout_finish(), vmsdbgout_global_decl(), vmsdbgout_ignore_block(), vmsdbgout_init(), vmsdbgout_source_line(), vmsdbgout_start_source_file(), vmsdbgout_type_decl(), and vmsdbgout_undef().
|
static |
Referenced by dwarf2out_alloc_current_fde(), dwarf2out_finish(), output_aranges(), output_call_frame_info(), and size_of_aranges().
|
static |
Filenames referenced by this compilation unit.
Referenced by dwarf2out_finish(), dwarf2out_init(), lookup_filename(), and output_file_names().
|
static |
Cached result of previous call to lookup_filename.
Referenced by lookup_filename().
|
static |
One above highest N where .LVLN label might be equal to .Ltext0 label.
Referenced by find_empty_loc_ranges_at_text_label().
|
static |
Offset from the "steady-state frame pointer" to the frame base, within the current function.
Referenced by based_loc_descr().
|
static |
Instances of generic types for which we need to generate debug info that describe their generic parameters and arguments. That generation needs to happen once all types are properly laid out so we do it at the end of compilation.
|
static |
Whether we have location lists that need outputting
|
static |
True if the compilation unit places functions in more than one section.
Referenced by dwarf2out_begin_function(), dwarf2out_end_function(), dwarf2out_finish(), dwarf2out_switch_text_section(), dwarf2out_var_location(), find_empty_loc_ranges_at_text_label(), output_aranges(), output_loc_list(), output_ranges(), and size_of_aranges().
|
static |
True if before or during processing of the first function being emitted.
A pointer to the base of a list of incomplete types which might be completed at some later time. incomplete_types_list needs to be a vec<tree, va_gc> *because we want to tell the garbage collector about it.
|
static |
A flag to tell pubnames/types export if there is an info section to refer to.
|
static |
Number of internal labels generated by gen_internal_sym().
|
static |
The last file entry emitted by maybe_emit_file().
|
static |
Referenced by dwarf2out_end_epilogue(), and dwarf2out_var_location().
|
static |
A list of DIEs with a NULL parent waiting to be relocated.
Referenced by break_out_includes(), dwarf2out_finish(), new_die(), and prune_unused_types().
|
static |
A global counter for generating labels for line number data.
Referenced by dwarf2out_source_line().
|
static |
|
static |
Unique label counter.
Referenced by dwarf2out_var_location().
|
static |
|
static |
A pointer to the base of a table that contains a list of macro defines/undefines (and file start/end markers).
|
static |
True if loc_note during dwarf2out_var_location call might still be before first real instruction at address equal to .Ltext0.
|
static |
This location is used by calc_die_sizes() to keep track the offset of each DIE within the .debug_info section.
Referenced by calc_die_sizes().
|
static |
Unique label counter for point-of-call tables.
|
static |
Keep track of the number of spaces used to indent the output of the debugging routines that print the structure of the DIE internal representation.
|
static |
|
static |
A pointer to the base of a table that contains a list of publicly accessible names.
|
static |
A pointer to the base of a table that contains a list of publicly accessible types.
|
static |
Array of pairs of labels referenced in ranges_table.
|
static |
Number of elements currently allocated for ranges_by_label.
|
static |
Number of elements in ranges_by_label currently in use.
Referenced by add_ranges_by_labels().
|
static |
|
static |
Array of dies for which we should generate .debug_ranges info.
|
static |
Number of elements currently allocated for ranges_table.
|
static |
Number of elements in ranges_table currently in use.
Referenced by add_ranges_num(), and output_ranges().
|
static |
The set of all non-default tables of line number info.
|
static |
Record the root of the DIE's built for the current compilation unit.
Referenced by comp_unit_die().
|
static |
With split_debug_info, both the comp_dir and dwo_name go in the main object file, rather than the dwo, similar to the force_direct parameter elsewhere but with additional complications: 1) The string is needed in both the main object file and the dwo. That is, the comp_dir and dwo_name will appear in both places. 2) Strings can use three forms: DW_FORM_string, DW_FORM_strp or DW_FORM_GNU_str_index. 3) GCC chooses the form to use late, depending on the size and reference count. Rather than forcing the all debug string handling functions and callers to deal with these complications, simply use a separate, special-cased string table for any attribute that should go in the main object file. This limits the complexity to just the places that need it.
|
static |
Number of tail call sites in the current function.
Referenced by dwarf2out_abstract_function(), dwarf2out_begin_function(), dwarf2out_function_decl(), dwarf2out_var_location(), and gen_subprogram_die().
|
static |
Definitions of defaults for formats and names of various special (artificial) labels which may be generated within this file (when the -g options is used and DWARF2_DEBUGGING_INFO is in effect. If necessary, these may be overridden from within the tm.h file, but typically, overriding these defaults is unnecessary.
Referenced by dw_loc_list(), and dwarf2out_init().
|
static |
Referenced by secname_for_decl().
|
static |
The two default tables of line number info.
Referenced by set_cur_line_info_table().
|
static |
Whether the default text and cold text sections have been used at all.
Referenced by dwarf2out_finish(), dwarf2out_note_section_used(), output_aranges(), and size_of_aranges().
|
static |