summaryrefslogtreecommitdiff
path: root/gcc/unroll.c
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/unroll.c')
-rw-r--r--gcc/unroll.c44
1 files changed, 22 insertions, 22 deletions
diff --git a/gcc/unroll.c b/gcc/unroll.c
index bf0c607dffc..f3f565681d8 100644
--- a/gcc/unroll.c
+++ b/gcc/unroll.c
@@ -355,7 +355,7 @@ unroll_loop (loop, insn_count, strength_reduce_p)
rtx ujump = ujump_to_loop_cont (loop->start, loop->cont);
if (ujump)
- delete_insn (ujump);
+ delete_related_insns (ujump);
/* If number of iterations is exactly 1, then eliminate the compare and
branch at the end of the loop since they will never be taken.
@@ -367,31 +367,31 @@ unroll_loop (loop, insn_count, strength_reduce_p)
if (GET_CODE (last_loop_insn) == BARRIER)
{
/* Delete the jump insn. This will delete the barrier also. */
- delete_insn (PREV_INSN (last_loop_insn));
+ delete_related_insns (PREV_INSN (last_loop_insn));
}
else if (GET_CODE (last_loop_insn) == JUMP_INSN)
{
#ifdef HAVE_cc0
rtx prev = PREV_INSN (last_loop_insn);
#endif
- delete_insn (last_loop_insn);
+ delete_related_insns (last_loop_insn);
#ifdef HAVE_cc0
/* The immediately preceding insn may be a compare which must be
deleted. */
if (only_sets_cc0_p (prev))
- delete_insn (prev);
+ delete_related_insns (prev);
#endif
}
/* Remove the loop notes since this is no longer a loop. */
if (loop->vtop)
- delete_insn (loop->vtop);
+ delete_related_insns (loop->vtop);
if (loop->cont)
- delete_insn (loop->cont);
+ delete_related_insns (loop->cont);
if (loop_start)
- delete_insn (loop_start);
+ delete_related_insns (loop_start);
if (loop_end)
- delete_insn (loop_end);
+ delete_related_insns (loop_end);
return;
}
@@ -1291,16 +1291,16 @@ unroll_loop (loop, insn_count, strength_reduce_p)
&& ! (GET_CODE (insn) == CODE_LABEL && LABEL_NAME (insn))
&& ! (GET_CODE (insn) == NOTE
&& NOTE_LINE_NUMBER (insn) == NOTE_INSN_DELETED_LABEL))
- insn = delete_insn (insn);
+ insn = delete_related_insns (insn);
else
insn = NEXT_INSN (insn);
}
/* Can now delete the 'safety' label emitted to protect us from runaway
- delete_insn calls. */
+ delete_related_insns calls. */
if (INSN_DELETED_P (safety_label))
abort ();
- delete_insn (safety_label);
+ delete_related_insns (safety_label);
/* If exit_label exists, emit it after the loop. Doing the emit here
forces it to have a higher INSN_UID than any insn in the unrolled loop.
@@ -1315,13 +1315,13 @@ unroll_loop (loop, insn_count, strength_reduce_p)
{
/* Remove the loop notes since this is no longer a loop. */
if (loop->vtop)
- delete_insn (loop->vtop);
+ delete_related_insns (loop->vtop);
if (loop->cont)
- delete_insn (loop->cont);
+ delete_related_insns (loop->cont);
if (loop_start)
- delete_insn (loop_start);
+ delete_related_insns (loop_start);
if (loop_end)
- delete_insn (loop_end);
+ delete_related_insns (loop_end);
}
if (map->const_equiv_varray)
@@ -1562,7 +1562,7 @@ calculate_giv_inc (pattern, src_insn, regno)
/* The last insn emitted is not needed, so delete it to avoid confusing
the second cse pass. This insn sets the giv unnecessarily. */
- delete_insn (get_last_insn ());
+ delete_related_insns (get_last_insn ());
}
/* Verify that we have a constant as the second operand of the plus. */
@@ -1601,7 +1601,7 @@ calculate_giv_inc (pattern, src_insn, regno)
src_insn = PREV_INSN (src_insn);
increment = SET_SRC (PATTERN (src_insn));
/* Don't need the last insn anymore. */
- delete_insn (get_last_insn ());
+ delete_related_insns (get_last_insn ());
if (GET_CODE (second_part) != CONST_INT
|| GET_CODE (increment) != CONST_INT)
@@ -1620,7 +1620,7 @@ calculate_giv_inc (pattern, src_insn, regno)
/* The insn loading the constant into a register is no longer needed,
so delete it. */
- delete_insn (get_last_insn ());
+ delete_related_insns (get_last_insn ());
}
if (increment_total)
@@ -1644,7 +1644,7 @@ calculate_giv_inc (pattern, src_insn, regno)
src_insn = PREV_INSN (src_insn);
pattern = PATTERN (src_insn);
- delete_insn (get_last_insn ());
+ delete_related_insns (get_last_insn ());
goto retry;
}
@@ -2148,7 +2148,7 @@ copy_loop_body (loop, copy_start, copy_end, map, exit_label, last_iteration,
#ifdef HAVE_cc0
/* If the previous insn set cc0 for us, delete it. */
if (only_sets_cc0_p (PREV_INSN (copy)))
- delete_insn (PREV_INSN (copy));
+ delete_related_insns (PREV_INSN (copy));
#endif
/* If this is now a no-op, delete it. */
@@ -2159,7 +2159,7 @@ copy_loop_body (loop, copy_start, copy_end, map, exit_label, last_iteration,
instruction in the loop. */
if (JUMP_LABEL (copy))
LABEL_NUSES (JUMP_LABEL (copy))++;
- delete_insn (copy);
+ delete_related_insns (copy);
if (JUMP_LABEL (copy))
LABEL_NUSES (JUMP_LABEL (copy))--;
copy = 0;
@@ -2954,7 +2954,7 @@ find_splittable_givs (loop, bl, unroll_type, increment, unroll_number)
/* We can't use bl->initial_value to compute the initial
value, because the loop may have been preconditioned.
We must calculate it from NEW_REG. */
- delete_insn (PREV_INSN (loop->start));
+ delete_related_insns (PREV_INSN (loop->start));
start_sequence ();
ret = force_operand (v->new_reg, tem);