aboutsummaryrefslogtreecommitdiff
path: root/gcc/flow.c
diff options
context:
space:
mode:
authorJeff Law <law@gcc.gnu.org>1998-12-02 02:14:57 -0700
committerJeff Law <law@gcc.gnu.org>1998-12-02 02:14:57 -0700
commitb7f7462b7a23b0e5465e66f1738f3caf22a38b65 (patch)
tree6d4572e2f7f7ef36b60eaf29f14af7759886dc81 /gcc/flow.c
parent2536e1eefe226d841cee6d45dd11031b75e862d8 (diff)
downloadgcc-b7f7462b7a23b0e5465e66f1738f3caf22a38b65.zip
gcc-b7f7462b7a23b0e5465e66f1738f3caf22a38b65.tar.gz
gcc-b7f7462b7a23b0e5465e66f1738f3caf22a38b65.tar.bz2
flow.c (delete_block): Call set_last_insn after we have reset NEXT_INSN (kept_tail).
8 * flow.c (delete_block): Call set_last_insn after we have reset NEXT_INSN (kept_tail). From-SVN: r24059
Diffstat (limited to 'gcc/flow.c')
-rw-r--r--gcc/flow.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/gcc/flow.c b/gcc/flow.c
index 825bf22..cc76a9c 100644
--- a/gcc/flow.c
+++ b/gcc/flow.c
@@ -1026,11 +1026,15 @@ delete_block (i)
NEXT_INSN (PREV_INSN (basic_block_head[i])) = kept_head;
if (insn != 0)
PREV_INSN (insn) = kept_tail;
- else
- set_last_insn (kept_tail);
PREV_INSN (kept_head) = PREV_INSN (basic_block_head[i]);
NEXT_INSN (kept_tail) = insn;
+
+ /* This must happen after NEXT_INSN (kept_tail) has been reinitialized
+ since set_last_insn will abort if it detects a non-NULL NEXT_INSN
+ field in its argument. */
+ if (insn == NULL_RTX)
+ set_last_insn (kept_tail);
}
/* Each time we delete some basic blocks,