diff options
Diffstat (limited to 'gcc/dwarf2out.h')
-rw-r--r-- | gcc/dwarf2out.h | 44 |
1 files changed, 44 insertions, 0 deletions
diff --git a/gcc/dwarf2out.h b/gcc/dwarf2out.h index 54b6343..057afdb 100644 --- a/gcc/dwarf2out.h +++ b/gcc/dwarf2out.h @@ -387,4 +387,48 @@ struct fixed_point_type_info void dwarf2out_c_finalize (void); +/* Some DWARF internals are exposed for the needs of DWARF-based debug + formats. */ + +/* 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 GTY(()) dw_attr_struct { + enum dwarf_attribute dw_attr; + dw_val_node dw_attr_val; +} +dw_attr_node; + +extern dw_attr_node *get_AT (dw_die_ref, enum dwarf_attribute); +extern HOST_WIDE_INT AT_int (dw_attr_node *); +extern unsigned HOST_WIDE_INT AT_unsigned (dw_attr_node *a); +extern dw_loc_descr_ref AT_loc (dw_attr_node *); +extern dw_die_ref get_AT_ref (dw_die_ref, enum dwarf_attribute); +extern const char *get_AT_string (dw_die_ref, enum dwarf_attribute); +extern enum dw_val_class AT_class (dw_attr_node *); +extern unsigned HOST_WIDE_INT AT_unsigned (dw_attr_node *); +extern unsigned get_AT_unsigned (dw_die_ref, enum dwarf_attribute); +extern int get_AT_flag (dw_die_ref, enum dwarf_attribute); + +extern void add_name_attribute (dw_die_ref, const char *); + +extern dw_die_ref new_die_raw (enum dwarf_tag); +extern dw_die_ref base_type_die (tree, bool); + +extern dw_die_ref lookup_decl_die (tree); + +extern dw_die_ref dw_get_die_child (dw_die_ref); +extern dw_die_ref dw_get_die_sib (dw_die_ref); +extern enum dwarf_tag dw_get_die_tag (dw_die_ref); + +/* Data about a single source file. */ +struct GTY((for_user)) dwarf_file_data { + const char * filename; + int emitted_number; +}; + +extern struct dwarf_file_data *get_AT_file (dw_die_ref, + enum dwarf_attribute); + #endif /* GCC_DWARF2OUT_H */ |