mirror of
git://gcc.gnu.org/git/gcc.git
synced 2025-04-02 05:50:26 +08:00
dwarf2out.h (dwarf2out_frame_debug_init): Declare.
* dwarf2out.h (dwarf2out_frame_debug_init): Declare. * dwarf2out.c (dwarf2out_frame_debug_init): New function, broken out of ... (dwarf2out_frame_debug): ... here. Don't handle a NULL argument. * final.c (final_start_function): Call the new function rather than using a NULL argument for dwarf2out_frame_debug. From-SVN: r171839
This commit is contained in:
parent
1ca1dad5f1
commit
722279e41f
@ -1,3 +1,12 @@
|
||||
2011-04-01 Bernd Schmidt <bernds@codesourcery.com>
|
||||
|
||||
* dwarf2out.h (dwarf2out_frame_debug_init): Declare.
|
||||
* dwarf2out.c (dwarf2out_frame_debug_init): New function, broken
|
||||
out of ...
|
||||
(dwarf2out_frame_debug): ... here. Don't handle a NULL argument.
|
||||
* final.c (final_start_function): Call the new function rather
|
||||
than using a NULL argument for dwarf2out_frame_debug.
|
||||
|
||||
2011-04-01 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
|
||||
|
||||
* config/spu/t-spu-elf (dp-bit.c): Use > instead of >>.
|
||||
|
@ -2788,38 +2788,6 @@ dwarf2out_frame_debug (rtx insn, bool after_p)
|
||||
rtx note, n;
|
||||
bool handled_one = false;
|
||||
|
||||
if (insn == NULL_RTX)
|
||||
{
|
||||
size_t i;
|
||||
|
||||
/* Flush any queued register saves. */
|
||||
dwarf2out_flush_queued_reg_saves ();
|
||||
|
||||
/* Set up state for generating call frame debug info. */
|
||||
lookup_cfa (&cfa);
|
||||
gcc_assert (cfa.reg
|
||||
== (unsigned long)DWARF_FRAME_REGNUM (STACK_POINTER_REGNUM));
|
||||
|
||||
cfa.reg = STACK_POINTER_REGNUM;
|
||||
cfa_store = cfa;
|
||||
cfa_temp.reg = -1;
|
||||
cfa_temp.offset = 0;
|
||||
|
||||
for (i = 0; i < num_regs_saved_in_regs; i++)
|
||||
{
|
||||
regs_saved_in_regs[i].orig_reg = NULL_RTX;
|
||||
regs_saved_in_regs[i].saved_in_reg = NULL_RTX;
|
||||
}
|
||||
num_regs_saved_in_regs = 0;
|
||||
|
||||
if (barrier_args_size)
|
||||
{
|
||||
XDELETEVEC (barrier_args_size);
|
||||
barrier_args_size = NULL;
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
if (!NONJUMP_INSN_P (insn) || clobbers_queued_reg_save (insn))
|
||||
dwarf2out_flush_queued_reg_saves ();
|
||||
|
||||
@ -2937,6 +2905,40 @@ dwarf2out_frame_debug (rtx insn, bool after_p)
|
||||
dwarf2out_flush_queued_reg_saves ();
|
||||
}
|
||||
|
||||
/* Called once at the start of final to initialize some data for the
|
||||
current function. */
|
||||
void
|
||||
dwarf2out_frame_debug_init (void)
|
||||
{
|
||||
size_t i;
|
||||
|
||||
/* Flush any queued register saves. */
|
||||
dwarf2out_flush_queued_reg_saves ();
|
||||
|
||||
/* Set up state for generating call frame debug info. */
|
||||
lookup_cfa (&cfa);
|
||||
gcc_assert (cfa.reg
|
||||
== (unsigned long)DWARF_FRAME_REGNUM (STACK_POINTER_REGNUM));
|
||||
|
||||
cfa.reg = STACK_POINTER_REGNUM;
|
||||
cfa_store = cfa;
|
||||
cfa_temp.reg = -1;
|
||||
cfa_temp.offset = 0;
|
||||
|
||||
for (i = 0; i < num_regs_saved_in_regs; i++)
|
||||
{
|
||||
regs_saved_in_regs[i].orig_reg = NULL_RTX;
|
||||
regs_saved_in_regs[i].saved_in_reg = NULL_RTX;
|
||||
}
|
||||
num_regs_saved_in_regs = 0;
|
||||
|
||||
if (barrier_args_size)
|
||||
{
|
||||
XDELETEVEC (barrier_args_size);
|
||||
barrier_args_size = NULL;
|
||||
}
|
||||
}
|
||||
|
||||
/* Determine if we need to save and restore CFI information around this
|
||||
epilogue. If SIBCALL is true, then this is a sibcall epilogue. If
|
||||
we do need to save/restore, then emit the save now, and insert a
|
||||
|
@ -1,5 +1,5 @@
|
||||
/* dwarf2out.h - Various declarations for functions found in dwarf2out.c
|
||||
Copyright (C) 1998, 1999, 2000, 2003, 2007, 2010
|
||||
Copyright (C) 1998, 1999, 2000, 2003, 2007, 2010, 2011
|
||||
Free Software Foundation, Inc.
|
||||
|
||||
This file is part of GCC.
|
||||
@ -20,6 +20,7 @@ along with GCC; see the file COPYING3. If not see
|
||||
|
||||
extern void dwarf2out_decl (tree);
|
||||
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);
|
||||
|
@ -1561,7 +1561,7 @@ final_start_function (rtx first ATTRIBUTE_UNUSED, FILE *file,
|
||||
|
||||
#if defined (HAVE_prologue)
|
||||
if (dwarf2out_do_frame ())
|
||||
dwarf2out_frame_debug (NULL_RTX, false);
|
||||
dwarf2out_frame_debug_init ();
|
||||
#endif
|
||||
|
||||
/* If debugging, assign block numbers to all of the blocks in this
|
||||
|
Loading…
x
Reference in New Issue
Block a user