Commit c470afad by Richard Kenner Committed by Richard Kenner

dwarf2out.c (save_rtx): Deleted.

	* dwarf2out.c (save_rtx): Deleted.
	(mem_loc_descriptor): Do equivalent operation.
	(add_const_value_attribute, case CONST): Likewise.
	(add_name_and_src_coords_attributes): Likewise.

From-SVN: r48266
parent 7a73ad55
Sat Dec 22 08:59:50 2001 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
* dwarf2out.c (save_rtx): Deleted.
(mem_loc_descriptor): Do equivalent operation.
(add_const_value_attribute, case CONST): Likewise.
(add_name_and_src_coords_attributes): Likewise.
2001-12-21 Kazu Hirata <kazu@hxi.com> 2001-12-21 Kazu Hirata <kazu@hxi.com>
* config/h8300/h8300.h: Fix comment formatting. * config/h8300/h8300.h: Fix comment formatting.
......
...@@ -3386,9 +3386,7 @@ static int comp_unit_has_inlines; ...@@ -3386,9 +3386,7 @@ static int comp_unit_has_inlines;
#endif #endif
/* Array of RTXes referenced by the debugging information, which therefore /* Array of RTXes referenced by the debugging information, which therefore
must be kept around forever. We do this rather than perform GC on must be kept around forever. This is a GC root. */
the dwarf info because almost all of the dwarf info lives forever, and
it's easier to support non-GC frontends this way. */
static varray_type used_rtx_varray; static varray_type used_rtx_varray;
/* Forward declarations for functions defined in this file. */ /* Forward declarations for functions defined in this file. */
...@@ -3604,7 +3602,6 @@ static void init_file_table PARAMS ((void)); ...@@ -3604,7 +3602,6 @@ static void init_file_table PARAMS ((void));
static void add_incomplete_type PARAMS ((tree)); static void add_incomplete_type PARAMS ((tree));
static void retry_incomplete_types PARAMS ((void)); static void retry_incomplete_types PARAMS ((void));
static void gen_type_die_for_member PARAMS ((tree, tree, dw_die_ref)); static void gen_type_die_for_member PARAMS ((tree, tree, dw_die_ref));
static rtx save_rtx PARAMS ((rtx));
static void splice_child_die PARAMS ((dw_die_ref, dw_die_ref)); static void splice_child_die PARAMS ((dw_die_ref, dw_die_ref));
static int file_info_cmp PARAMS ((const void *, const void *)); static int file_info_cmp PARAMS ((const void *, const void *));
static dw_loc_list_ref new_loc_list PARAMS ((dw_loc_descr_ref, static dw_loc_list_ref new_loc_list PARAMS ((dw_loc_descr_ref,
...@@ -3736,19 +3733,6 @@ dwarf2out_set_demangle_name_func (func) ...@@ -3736,19 +3733,6 @@ dwarf2out_set_demangle_name_func (func)
{ {
demangle_name_func = func; demangle_name_func = func;
} }
/* Return an rtx like ORIG which lives forever. If we're doing GC,
that means adding it to used_rtx_varray. If not, that means making
a copy on the permanent_obstack. */
static rtx
save_rtx (orig)
rtx orig;
{
VARRAY_PUSH_RTX (used_rtx_varray, orig);
return orig;
}
/* Test if rtl node points to a pseudo register. */ /* Test if rtl node points to a pseudo register. */
...@@ -7770,7 +7754,8 @@ mem_loc_descriptor (rtl, mode) ...@@ -7770,7 +7754,8 @@ mem_loc_descriptor (rtl, mode)
mem_loc_result = new_loc_descr (DW_OP_addr, 0, 0); mem_loc_result = new_loc_descr (DW_OP_addr, 0, 0);
mem_loc_result->dw_loc_oprnd1.val_class = dw_val_class_addr; mem_loc_result->dw_loc_oprnd1.val_class = dw_val_class_addr;
mem_loc_result->dw_loc_oprnd1.v.val_addr = save_rtx (rtl); mem_loc_result->dw_loc_oprnd1.v.val_addr = rtl;
VARRAY_PUSH_RTX (used_rtx_varray, rtl);
break; break;
case PRE_MODIFY: case PRE_MODIFY:
...@@ -8623,7 +8608,8 @@ add_const_value_attribute (die, rtl) ...@@ -8623,7 +8608,8 @@ add_const_value_attribute (die, rtl)
case SYMBOL_REF: case SYMBOL_REF:
case LABEL_REF: case LABEL_REF:
case CONST: case CONST:
add_AT_addr (die, DW_AT_const_value, save_rtx (rtl)); add_AT_addr (die, DW_AT_const_value, rtl);
VARRAY_PUSH_RTX (used_rtx_varray, rtl);
break; break;
case PLUS: case PLUS:
...@@ -9365,8 +9351,11 @@ add_name_and_src_coords_attributes (die, decl) ...@@ -9365,8 +9351,11 @@ add_name_and_src_coords_attributes (die, decl)
/* Get the function's name, as described by its RTL. This may be different /* Get the function's name, as described by its RTL. This may be different
from the DECL_NAME name used in the source file. */ from the DECL_NAME name used in the source file. */
if (TREE_CODE (decl) == FUNCTION_DECL && TREE_ASM_WRITTEN (decl)) if (TREE_CODE (decl) == FUNCTION_DECL && TREE_ASM_WRITTEN (decl))
add_AT_addr (die, DW_AT_VMS_rtnbeg_pd_address, {
save_rtx (XEXP (DECL_RTL (decl), 0))); add_AT_addr (die, DW_AT_VMS_rtnbeg_pd_address,
XEXP (DECL_RTL (decl), 0));
VARRAY_PUSH_RTX (used_rtx_varray, XEXP (DECL_RTL (decl), 0));
}
#endif #endif
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment