vsx.md (*vsx_extract_<mode>_load): Always match selection of 0th memory doubleword...
authorBill Schmidt <wschmidt@linux.vnet.ibm.com>
Thu, 4 Sep 2014 14:27:45 +0000 (14:27 +0000)
committerWilliam Schmidt <wschmidt@gcc.gnu.org>
Thu, 4 Sep 2014 14:27:45 +0000 (14:27 +0000)
[gcc]

2014-09-04  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>

* config/rs6000/vsx.md (*vsx_extract_<mode>_load): Always match
selection of 0th memory doubleword, regardless of endianness.

[gcc/testsuite]

2014-09-04  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>

* gcc.target/powerpc/vsx-extract-1.c:  Test 0th doubleword
regardless of endianness.

From-SVN: r214902

gcc/ChangeLog
gcc/config/rs6000/vsx.md
gcc/testsuite/ChangeLog
gcc/testsuite/gcc.target/powerpc/vsx-extract-1.c

index d341bff..c6042b5 100644 (file)
@@ -1,3 +1,8 @@
+2014-09-04  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
+
+       * config/rs6000/vsx.md (*vsx_extract_<mode>_load): Always match
+       selection of 0th memory doubleword, regardless of endianness.
+
 2014-09-04  Jan-Benedict Glaw  <jbglaw@lug-owl.de>
 
        * config/rx/rx.h (HARD_REGNO_MODE_OK): Add braces.
index 922471f..dc78a61 100644 (file)
   [(set (match_operand:<VS_scalar> 0 "register_operand" "=d,wv,wr")
        (vec_select:<VS_scalar>
         (match_operand:VSX_D 1 "memory_operand" "m,Z,m")
-        (parallel [(match_operand:QI 2 "vsx_scalar_64bit" "wD,wD,wD")])))]
+        (parallel [(const_int 0)])))]
   "VECTOR_MEM_VSX_P (<MODE>mode)"
   "@
    lfd%U1%X1 %0,%1
index 1312e4e..3143e32 100644 (file)
@@ -1,3 +1,8 @@
+2014-09-04  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
+
+       * gcc.target/powerpc/vsx-extract-1.c:  Test 0th doubleword
+       regardless of endianness.
+
 2014-09-02  Fritz Reese  <Reese-Fritz@zai.com>
 
        PR fortran/62174
index e1f0ca8..c4e76e6 100644 (file)
@@ -7,10 +7,4 @@
 
 #include <altivec.h>
 
-#if __LITTLE_ENDIAN__
-#define OFFSET 1
-#else
-#define OFFSET 0
-#endif
-
-double get_value (vector double *p) { return vec_extract (*p, OFFSET); }
+double get_value (vector double *p) { return vec_extract (*p, 0); }