From 4f8344ebbd28230f55822c1e9402cc73f2d6f077 Mon Sep 17 00:00:00 2001 From: Hans-Peter Nilsson Date: Mon, 27 Sep 2010 19:56:32 +0000 Subject: emit-rtl.c (reorder_insns_nobb): Sanity-check that AFTER is not in the range FROM..TO, inclusive. * emit-rtl.c (reorder_insns_nobb) [ENABLE_CHECKING]: Sanity-check that AFTER is not in the range FROM..TO, inclusive. From-SVN: r164664 --- gcc/emit-rtl.c | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'gcc/emit-rtl.c') diff --git a/gcc/emit-rtl.c b/gcc/emit-rtl.c index 35a4360..16032e9 100644 --- a/gcc/emit-rtl.c +++ b/gcc/emit-rtl.c @@ -3977,6 +3977,13 @@ delete_insns_since (rtx from) void reorder_insns_nobb (rtx from, rtx to, rtx after) { +#ifdef ENABLE_CHECKING + rtx x; + for (x = from; x != to; x = NEXT_INSN (x)) + gcc_assert (after != x); + gcc_assert (after != to); +#endif + /* Splice this bunch out of where it is now. */ if (PREV_INSN (from)) NEXT_INSN (PREV_INSN (from)) = NEXT_INSN (to); -- cgit v1.1