===================================================================
@@ -2697,6 +2697,8 @@ create_expression_by_pieces (basic_block
that value numbering saw through. */
case NAME:
folded = PRE_EXPR_NAME (expr);
+ if (SSA_NAME_OCCURS_IN_ABNORMAL_PHI (folded))
+ return NULL_TREE;
if (useless_type_conversion_p (exprtype, TREE_TYPE (folded)))
return folded;
break;
===================================================================
@@ -0,0 +1,20 @@
+/* { dg-do compile } */
+
+int _setjmp (void *);
+void foo (int);
+
+void
+bar (int e, int b, char c, void *d)
+{
+ while (b)
+ {
+ if (_setjmp (d))
+ foo (e);
+ if (c)
+ {
+ e--;
+ foo (0);
+ }
+ e++;
+ }
+}