+2003-03-23 Richard Henderson <rth@redhat.com>
+
+ PR opt/10116
+ * ifcvt.c (find_if_block): Disallow tablejump insns outgoing
+ from then_bb or else_bb after flow2.
+
2003-03-23 Zack Weinberg <zack@codesourcery.com>
* configure.in: Check whether it is necessary to link against
/* The THEN block of an IF-THEN combo must have zero or one successors. */
if (then_succ != NULL_EDGE
&& (then_succ->succ_next != NULL_EDGE
- || (then_succ->flags & EDGE_COMPLEX)))
+ || (then_succ->flags & EDGE_COMPLEX)
+ || (flow2_completed && tablejump_p (then_bb->end, NULL, NULL))))
return FALSE;
/* If the THEN block has no successors, conditional execution can still
&& then_succ->dest == else_succ->dest
&& else_bb->pred->pred_next == NULL_EDGE
&& else_succ->succ_next == NULL_EDGE
- && ! (else_succ->flags & EDGE_COMPLEX))
+ && ! (else_succ->flags & EDGE_COMPLEX)
+ && ! (flow2_completed && tablejump_p (else_bb->end, NULL, NULL)))
join_bb = else_succ->dest;
/* Otherwise it is not an IF-THEN or IF-THEN-ELSE combination. */