]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
Use INTVAL only on CONST_INT in addptrdi3 and addptrsi3
authorTom de Vries <tom@codesourcery.com>
Wed, 4 Jun 2014 20:18:47 +0000 (20:18 +0000)
committerTom de Vries <vries@gcc.gnu.org>
Wed, 4 Jun 2014 20:18:47 +0000 (20:18 +0000)
2014-06-04  Tom de Vries  <tom@codesourcery.com>

* config/s390/s390.md ("addptrdi3", "addptrsi3"): Use INTVAL only on
CONST_INT.

From-SVN: r211246

gcc/ChangeLog
gcc/config/s390/s390.md

index ca574c002ef3bd2806346b798c275ddaf3b3fed1..2a23c319a18bd14f75e9907833539eb4144e1065 100644 (file)
@@ -1,3 +1,8 @@
+2014-06-04  Tom de Vries  <tom@codesourcery.com>
+
+       * config/s390/s390.md ("addptrdi3", "addptrsi3"): Use INTVAL only on
+       CONST_INT.
+
 2014-06-04  Marc Glisse  <marc.glisse@inria.fr>
 
        PR tree-optimization/61385
index b17c1fac8752c0acf95431c62236ebeb9c512a1d..5fdbdbe860476d31ed3099ee73f3c60801e92fc4 100644 (file)
                 (match_operand:DI 2 "nonmemory_operand" "")))]
   "TARGET_64BIT"
 {
-  HOST_WIDE_INT c = INTVAL (operands[2]);
-
   if (GET_CODE (operands[2]) == CONST_INT)
     {
+      HOST_WIDE_INT c = INTVAL (operands[2]);
+
       if (!CONST_OK_FOR_CONSTRAINT_P (c, 'K', "K")
          && !CONST_OK_FOR_CONSTRAINT_P (c, 'O', "Os"))
         {
                   (use (const_int 0))])]
   "!TARGET_64BIT"
 {
-  HOST_WIDE_INT c = INTVAL (operands[2]);
-
   if (GET_CODE (operands[2]) == CONST_INT)
     {
+      HOST_WIDE_INT c = INTVAL (operands[2]);
+
       if (!CONST_OK_FOR_CONSTRAINT_P (c, 'K', "K")
          && !CONST_OK_FOR_CONSTRAINT_P (c, 'O', "Os"))
         {