(simplify_rtx): For (not (xor X C)) generate new rtx
authorwilson <wilson@138bc75d-0d04-0410-961f-82ee72b054a4>
Thu, 21 Jul 1994 22:06:05 +0000 (22:06 +0000)
committerwilson <wilson@138bc75d-0d04-0410-961f-82ee72b054a4>
Thu, 21 Jul 1994 22:06:05 +0000 (22:06 +0000)
instead of modifying old rtx.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@7788 138bc75d-0d04-0410-961f-82ee72b054a4

gcc/combine.c

index 990fa4d..9307af2 100644 (file)
@@ -3261,10 +3261,7 @@ simplify_rtx (x, op0_mode, last, in_dest)
          && (temp = simplify_unary_operation (NOT, mode,
                                               XEXP (XEXP (x, 0), 1),
                                               mode)) != 0)
-       {
-         SUBST (XEXP (XEXP (x, 0), 1), temp);
-         return XEXP (x, 0);
-       }
+       return gen_binary (XOR, mode, XEXP (XEXP (x, 0), 0), temp);
              
       /* (not (ashift 1 X)) is (rotate ~1 X).  We used to do this for operands
         other than 1, but that is not valid.  We could do a similar