]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
expr.c (expand_expr): Don't use simplify_binary_operation; check for zero operands...
authorEric Botcazou <ebotcazou@libertysurf.fr>
Tue, 29 Oct 2002 14:17:33 +0000 (15:17 +0100)
committerRichard Henderson <rth@gcc.gnu.org>
Tue, 29 Oct 2002 14:17:33 +0000 (06:17 -0800)
        * expr.c (expand_expr) [PLUS]: Don't use simplify_binary_operation;
        check for zero operands explicitly.

From-SVN: r58622

gcc/ChangeLog
gcc/expr.c

index 9229d2adb427af30e8af5ce08b3403a5922ddc97..33b313ff3fa00216246d7fc9873cb346fb2896ae 100644 (file)
@@ -1,3 +1,8 @@
+2002-10-29  Eric Botcazou  <ebotcazou@libertysurf.fr>
+
+       * expr.c (expand_expr) [PLUS]: Don't use simplify_binary_operation;
+       check for zero operands explicitly.
+
 2002-10-21  Dale Johannesen  <dalej@apple.com>
 
        PR target/7133
index a1045de2a45ef1d9f3554e88f46daf7524e890b3..25d1fad1a3f1ac8aa556d5a5c14e2aa4be477d9a 100644 (file)
@@ -7600,9 +7600,10 @@ expand_expr (exp, target, tmode, modifier)
        {
          op0 = expand_expr (TREE_OPERAND (exp, 0), subtarget, VOIDmode, 0);
          op1 = expand_expr (TREE_OPERAND (exp, 1), NULL_RTX, VOIDmode, 0);
-         temp = simplify_binary_operation (PLUS, mode, op0, op1);
-         if (temp)
-           return temp;
+         if (op0 == const0_rtx)
+           return op1;
+         if (op1 == const0_rtx)
+           return op0;
          goto binop2;
        }