re PR rtl-optimization/70261 (r234265 causes fails on rs6000)
authorJakub Jelinek <jakub@redhat.com>
Thu, 17 Mar 2016 08:01:26 +0000 (09:01 +0100)
committerJakub Jelinek <jakub@gcc.gnu.org>
Thu, 17 Mar 2016 08:01:26 +0000 (09:01 +0100)
PR target/70261
* rtlanal.c (replace_rtx): Revert 2016-03-16 change.

From-SVN: r234279

gcc/ChangeLog
gcc/rtlanal.c

index d7640c7d1d98c0b7764f6374e54e9a37f0485a4c..00bc1a6e4915092d929f2cc5f35f0be57b944850 100644 (file)
@@ -1,3 +1,8 @@
+2016-03-17  Jakub Jelinek  <jakub@redhat.com>
+
+       PR target/70261
+       * rtlanal.c (replace_rtx): Revert 2016-03-16 change.
+
 2016-03-16  Richard Henderson  <rth@redhat.com>
            Richard Biener  <rguenth@suse.de>
 
index 74b593d6935fca944704842efb210ddb3440dfeb..bacc5f25f4af20ed5dd0b7118cccea8ce57d0a13 100644 (file)
@@ -2961,16 +2961,7 @@ replace_rtx (rtx x, rtx from, rtx to)
   if (x == 0)
     return 0;
 
-  if (GET_CODE (x) == REG)
-    {
-      if (GET_CODE (from) == REG
-         && REGNO (x) == REGNO (from))
-       {
-         gcc_assert (GET_MODE (x) == GET_MODE (from));
-         return to;
-       }
-    }
-  else if (GET_CODE (x) == SUBREG)
+  if (GET_CODE (x) == SUBREG)
     {
       rtx new_rtx = replace_rtx (SUBREG_REG (x), from, to);