aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorRichard Henderson <rth@redhat.com>2011-07-05 10:14:16 -0700
committerRichard Henderson <rth@gcc.gnu.org>2011-07-05 10:14:16 -0700
commit499566678c005682a57d6d693abd76acdc849ca6 (patch)
treecf2c11657a1463f21eeb264da1d773d901f3ce6e /gcc
parentc2b40eba3ab707ce122464620bbdabf8b9044452 (diff)
downloadgcc-499566678c005682a57d6d693abd76acdc849ca6.zip
gcc-499566678c005682a57d6d693abd76acdc849ca6.tar.gz
gcc-499566678c005682a57d6d693abd76acdc849ca6.tar.bz2
dwarf2out: Remove unused text-based unwind entry points.
The dwarf2out_cfi_label function is privatized, the dwarf2out_def_cfa function is merged into its last user. The others really are unused. * dwarf2out.c (dwarf2out_cfi_label): Make static. (dwarf2out_flush_queued_reg_saves): Make static. (dwarf2out_reg_save): Remove. (dwarf2out_return_save): Remove. (dwarf2out_return_reg): Remove. (dwarf2out_reg_save_reg): Remove. (dwarf2out_def_cfa): Merge into ... (dwarf2out_frame_init): ... here. * dwarf2out.h, tree.h: Remove declarations as necessary. From-SVN: r175876
Diffstat (limited to 'gcc')
-rw-r--r--gcc/ChangeLog12
-rw-r--r--gcc/dwarf2out.c67
-rw-r--r--gcc/dwarf2out.h1
-rw-r--r--gcc/tree.h27
4 files changed, 20 insertions, 87 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 4ab0abf..70de80a 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,5 +1,17 @@
2011-07-05 Richard Henderson <rth@redhat.com>
+ * dwarf2out.c (dwarf2out_cfi_label): Make static.
+ (dwarf2out_flush_queued_reg_saves): Make static.
+ (dwarf2out_reg_save): Remove.
+ (dwarf2out_return_save): Remove.
+ (dwarf2out_return_reg): Remove.
+ (dwarf2out_reg_save_reg): Remove.
+ (dwarf2out_def_cfa): Merge into ...
+ (dwarf2out_frame_init): ... here.
+ * dwarf2out.h, tree.h: Remove declarations as necessary.
+
+2011-07-05 Richard Henderson <rth@redhat.com>
+
* config/ia64/ia64.c (ia64_dwarf_handle_frame_unspec): Remove.
(TARGET_DWARF_HANDLE_FRAME_UNSPEC): Remove.
(ia64_expand_epilogue): Emit an empty FRAME_RELATED_EXPR for
diff --git a/gcc/dwarf2out.c b/gcc/dwarf2out.c
index a0714c4..436110e 100644
--- a/gcc/dwarf2out.c
+++ b/gcc/dwarf2out.c
@@ -848,7 +848,7 @@ add_cfi (cfi_vec *vec, dw_cfi_ref cfi)
/* Generate a new label for the CFI info to refer to. FORCE is true
if a label needs to be output even when using .cfi_* directives. */
-char *
+static char *
dwarf2out_cfi_label (bool force)
{
static char label[20];
@@ -1080,21 +1080,6 @@ static HOST_WIDE_INT args_size;
/* The last args_size we actually output. */
static HOST_WIDE_INT old_args_size;
-/* Entry point to update the canonical frame address (CFA).
- LABEL is passed to add_fde_cfi. The value of CFA is now to be
- calculated from REG+OFFSET. */
-
-void
-dwarf2out_def_cfa (const char *label, unsigned int reg, HOST_WIDE_INT offset)
-{
- dw_cfa_location loc;
- loc.indirect = 0;
- loc.base_offset = 0;
- loc.reg = reg;
- loc.offset = offset;
- def_cfa_1 (label, &loc);
-}
-
/* Determine if two dw_cfa_location structures define the same data. */
static bool
@@ -1232,33 +1217,6 @@ reg_save (const char *label, unsigned int reg, unsigned int sreg, HOST_WIDE_INT
add_fde_cfi (label, cfi);
}
-/* Entry point for saving a register to the stack. REG is the GCC register
- number. LABEL and OFFSET are passed to reg_save. */
-
-void
-dwarf2out_reg_save (const char *label, unsigned int reg, HOST_WIDE_INT offset)
-{
- reg_save (label, DWARF_FRAME_REGNUM (reg), INVALID_REGNUM, offset);
-}
-
-/* Entry point for saving the return address in the stack.
- LABEL and OFFSET are passed to reg_save. */
-
-void
-dwarf2out_return_save (const char *label, HOST_WIDE_INT offset)
-{
- reg_save (label, DWARF_FRAME_RETURN_COLUMN, INVALID_REGNUM, offset);
-}
-
-/* Entry point for saving the return address in a register.
- LABEL and SREG are passed to reg_save. */
-
-void
-dwarf2out_return_reg (const char *label, unsigned int sreg)
-{
- reg_save (label, DWARF_FRAME_RETURN_COLUMN, DWARF_FRAME_REGNUM (sreg), 0);
-}
-
/* Record the initial position of the return address. RTL is
INCOMING_RETURN_ADDR_RTX. */
@@ -1816,7 +1774,7 @@ queue_reg_save (const char *label, rtx reg, rtx sreg, HOST_WIDE_INT offset)
/* Output all the entries in QUEUED_REG_SAVES. */
-void
+static void
dwarf2out_flush_queued_reg_saves (void)
{
struct queued_reg_save *q;
@@ -1866,20 +1824,6 @@ clobbers_queued_reg_save (const_rtx insn)
return false;
}
-/* Entry point for saving the first register into the second. */
-
-void
-dwarf2out_reg_save_reg (const char *label, rtx reg, rtx sreg)
-{
- unsigned int regno, sregno;
-
- record_reg_saved_in_reg (sreg, reg);
-
- regno = DWARF_FRAME_REGNUM (REGNO (reg));
- sregno = DWARF_FRAME_REGNUM (REGNO (sreg));
- reg_save (label, regno, sregno, 0);
-}
-
/* What register, if any, is currently saved in REG? */
static rtx
@@ -4273,6 +4217,8 @@ dwarf2out_end_epilogue (unsigned int line ATTRIBUTE_UNUSED,
void
dwarf2out_frame_init (void)
{
+ dw_cfa_location loc;
+
/* Allocate the initial hunk of the fde_table. */
fde_table = ggc_alloc_cleared_vec_dw_fde_node (FDE_TABLE_INCREMENT);
fde_table_allocated = FDE_TABLE_INCREMENT;
@@ -4282,7 +4228,10 @@ dwarf2out_frame_init (void)
sake of lookup_cfa. */
/* On entry, the Canonical Frame Address is at SP. */
- dwarf2out_def_cfa (NULL, STACK_POINTER_REGNUM, INCOMING_FRAME_SP_OFFSET);
+ memset(&loc, 0, sizeof (loc));
+ loc.reg = STACK_POINTER_REGNUM;
+ loc.offset = INCOMING_FRAME_SP_OFFSET;
+ def_cfa_1 (NULL, &loc);
if (targetm.debug_unwind_info () == UI_DWARF2
|| targetm_common.except_unwind_info (&global_options) == UI_DWARF2)
diff --git a/gcc/dwarf2out.h b/gcc/dwarf2out.h
index 7f5ac13..ca2c26a 100644
--- a/gcc/dwarf2out.h
+++ b/gcc/dwarf2out.h
@@ -23,7 +23,6 @@ extern void dwarf2out_frame_debug (rtx, bool);
extern void dwarf2out_frame_debug_init (void);
extern void dwarf2out_cfi_begin_epilogue (rtx);
extern void dwarf2out_frame_debug_restore_state (void);
-extern void dwarf2out_flush_queued_reg_saves (void);
extern void debug_dwarf (void);
struct die_struct;
diff --git a/gcc/tree.h b/gcc/tree.h
index ab0b6cc..fd7d5ce 100644
--- a/gcc/tree.h
+++ b/gcc/tree.h
@@ -5602,33 +5602,6 @@ extern tree tree_overlaps_hard_reg_set (tree, HARD_REG_SET *);
#endif
-/* In dwarf2out.c */
-/* Interface of the DWARF2 unwind info support. */
-
-/* Generate a new label for the CFI info to refer to. */
-
-extern char *dwarf2out_cfi_label (bool);
-
-/* Entry point to update the canonical frame address (CFA). */
-
-extern void dwarf2out_def_cfa (const char *, unsigned, HOST_WIDE_INT);
-
-/* Entry point for saving a register to the stack. */
-
-extern void dwarf2out_reg_save (const char *, unsigned, HOST_WIDE_INT);
-
-/* Entry point for saving the return address in the stack. */
-
-extern void dwarf2out_return_save (const char *, HOST_WIDE_INT);
-
-/* Entry point for saving the return address in a register. */
-
-extern void dwarf2out_return_reg (const char *, unsigned);
-
-/* Entry point for saving the first register into the second. */
-
-extern void dwarf2out_reg_save_reg (const char *, rtx, rtx);
-
/* In tree-inline.c */
/* The type of a set of already-visited pointers. Functions for creating