diff options
author | rth <rth@138bc75d-0d04-0410-961f-82ee72b054a4> | 2000-05-19 20:07:18 +0000 |
---|---|---|
committer | rth <rth@138bc75d-0d04-0410-961f-82ee72b054a4> | 2000-05-19 20:07:18 +0000 |
commit | 447095c03716a0cae4a124a3604b70589802e380 (patch) | |
tree | 1279ef32590b83c555c5adb2aa805a92077c8cd9 /gcc/ifcvt.c | |
parent | 62cddb26191285628817cd1a10cc1196388c275d (diff) | |
download | gcc-447095c03716a0cae4a124a3604b70589802e380.tar.gz |
* ifcvt.c (find_if_case_2): Don't allow THEN to be EXIT.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@34036 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/ifcvt.c')
-rw-r--r-- | gcc/ifcvt.c | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/gcc/ifcvt.c b/gcc/ifcvt.c index 24036513b65..371e5609353 100644 --- a/gcc/ifcvt.c +++ b/gcc/ifcvt.c @@ -1652,14 +1652,17 @@ find_if_case_2 (test_bb, then_edge, else_edge) if (else_bb->pred->pred_next != NULL) return FALSE; + /* THEN is not EXIT. */ + if (then_bb->index < 0) + return FALSE; + /* ELSE is predicted or SUCC(ELSE) postdominates THEN. */ note = find_reg_note (test_bb->end, REG_BR_PROB, NULL_RTX); if (note && INTVAL (XEXP (note, 0)) >= REG_BR_PROB_BASE / 2) ; else if (else_succ->dest->index < 0 - || (then_bb->index >= 0 - && TEST_BIT (post_dominators[ORIG_INDEX (then_bb)], - ORIG_INDEX (else_succ->dest)))) + || TEST_BIT (post_dominators[ORIG_INDEX (then_bb)], + ORIG_INDEX (else_succ->dest))) ; else return FALSE; |