combine.c (simplify_set): Do not clear out undobuf.other_insn already set elsewhere.
authorUlrich Weigand <uweigand@de.ibm.com>
Fri, 17 Oct 2003 13:36:48 +0000 (13:36 +0000)
committerUlrich Weigand <uweigand@gcc.gnu.org>
Fri, 17 Oct 2003 13:36:48 +0000 (13:36 +0000)
* combine.c (simplify_set): Do not clear out undobuf.other_insn
already set elsewhere.

From-SVN: r72602

gcc/ChangeLog
gcc/combine.c

index b82a371ef2dd4e66bd32e46a1dfbae9ac68ea527..8f5c802b05fdb44de0daccfc3255b46bca2c3588 100644 (file)
@@ -1,3 +1,8 @@
+2003-10-17  Ulrich Weigand  <uweigand@de.ibm.com>
+
+       * combine.c (simplify_set): Do not clear out undobuf.other_insn
+       already set elsewhere.
+
 2003-10-17  Kelley Cook  <kcook@gcc.gnu.org>
 
        * config/i386/i386.c (ix86_expand_prologue):  Use
index cac585a69c0261960711c474140a86914628fc86..c36d9223724f5192b74141f05b36c5cd080fcd26 100644 (file)
@@ -5084,10 +5084,12 @@ simplify_set (rtx x)
         undobuf.other_insn.  */
       if (new_code != old_code)
        {
+         int other_changed_previously = other_changed;
          unsigned HOST_WIDE_INT mask;
 
          SUBST (*cc_use, gen_rtx_fmt_ee (new_code, GET_MODE (*cc_use),
                                          dest, const0_rtx));
+         other_changed = 1;
 
          /* If the only change we made was to change an EQ into an NE or
             vice versa, OP0 has only one bit that might be nonzero, and OP1
@@ -5097,7 +5099,7 @@ simplify_set (rtx x)
 
          if (((old_code == NE && new_code == EQ)
               || (old_code == EQ && new_code == NE))
-             && ! other_changed && op1 == const0_rtx
+             && ! other_changed_previously && op1 == const0_rtx
              && GET_MODE_BITSIZE (GET_MODE (op0)) <= HOST_BITS_PER_WIDE_INT
              && exact_log2 (mask = nonzero_bits (op0, GET_MODE (op0))) >= 0)
            {
@@ -5107,13 +5109,11 @@ simplify_set (rtx x)
                   && ! check_asm_operands (pat)))
                {
                  PUT_CODE (*cc_use, old_code);
-                 other_insn = 0;
+                 other_changed = 0;
 
                  op0 = gen_binary (XOR, GET_MODE (op0), op0, GEN_INT (mask));
                }
            }
-
-         other_changed = 1;
        }
 
       if (other_changed)