#include "config.h"
#include "system.h"
#include "coretypes.h"
-#include "tm.h"
-#include "diagnostic-core.h"
+#include "backend.h"
#include "rtl.h"
+#include "df.h"
+#include "diagnostic-core.h"
#include "tm_p.h"
-#include "hard-reg-set.h"
-#include "hashtab.h"
-#include "hash-set.h"
-#include "vec.h"
-#include "machmode.h"
-#include "input.h"
-#include "function.h"
#include "regs.h"
#include "flags.h"
#include "output.h"
-#include "dominance.h"
-#include "cfg.h"
-#include "predict.h"
-#include "basic-block.h"
#include "resource.h"
#include "except.h"
#include "insn-attr.h"
#include "params.h"
-#include "df.h"
+#include "emit-rtl.h"
/* This structure is used to record liveness information at the targets or
fallthrough insns of branches. We will most likely need the information
else
{
first_regno = REGNO (dest);
- last_regno = END_HARD_REGNO (dest);
+ last_regno = END_REGNO (dest);
}
if (GET_CODE (x) == CLOBBER)
for (insn = target; insn; insn = next_insn)
{
- rtx_insn *this_jump_insn = insn;
+ rtx_insn *this_insn = insn;
next_insn = NEXT_INSN (insn);
of a call, so search for a JUMP_INSN in any position. */
for (i = 0; i < seq->len (); i++)
{
- this_jump_insn = seq->insn (i);
- if (JUMP_P (this_jump_insn))
+ this_insn = seq->insn (i);
+ if (JUMP_P (this_insn))
break;
}
}
break;
}
- if (JUMP_P (this_jump_insn))
+ if (rtx_jump_insn *this_jump_insn =
+ dyn_cast <rtx_jump_insn *> (this_insn))
{
if (jump_count++ < 10)
{
if (any_uncondjump_p (this_jump_insn)
|| ANY_RETURN_P (PATTERN (this_jump_insn)))
{
- rtx lab_or_return = JUMP_LABEL (this_jump_insn);
+ rtx lab_or_return = this_jump_insn->jump_label ();
if (ANY_RETURN_P (lab_or_return))
next_insn = NULL;
else
AND_COMPL_HARD_REG_SET (scratch, needed.regs);
AND_COMPL_HARD_REG_SET (fallthrough_res.regs, scratch);
- if (!ANY_RETURN_P (JUMP_LABEL (this_jump_insn)))
- find_dead_or_set_registers (JUMP_LABEL_AS_INSN (this_jump_insn),
- &target_res, 0, jump_count,
- target_set, needed);
+ if (!ANY_RETURN_P (this_jump_insn->jump_label ()))
+ find_dead_or_set_registers
+ (this_jump_insn->jump_target (),
+ &target_res, 0, jump_count, target_set, needed);
find_dead_or_set_registers (next_insn,
&fallthrough_res, 0, jump_count,
set, needed);
unsigned int i;
struct target_info *tinfo = NULL;
rtx_insn *insn;
- rtx jump_insn = 0;
rtx jump_target;
HARD_REG_SET scratch;
struct resources set, needed;
CLEAR_RESOURCE (&set);
CLEAR_RESOURCE (&needed);
- jump_insn = find_dead_or_set_registers (target, res, &jump_target, 0,
- set, needed);
+ rtx_insn *jump_insn = find_dead_or_set_registers (target, res, &jump_target,
+ 0, set, needed);
/* If we hit an unconditional branch, we have another way of finding out
what is live: we can see what is live at the branch target and include
&end_of_function_needs, true);
for (i = 0; i < FIRST_PSEUDO_REGISTER; i++)
- if (global_regs[i]
-#ifdef EPILOGUE_USES
- || EPILOGUE_USES (i)
-#endif
- )
+ if (global_regs[i] || EPILOGUE_USES (i))
SET_HARD_REG_BIT (end_of_function_needs.regs, i);
/* The registers required to be live at the end of the function are