* gcc.target/powerpc/ppc-vector-memcpy.c: Test use of VMX for memcpy
authordje <dje@138bc75d-0d04-0410-961f-82ee72b054a4>
Fri, 26 Jul 2013 11:49:12 +0000 (11:49 +0000)
committerdje <dje@138bc75d-0d04-0410-961f-82ee72b054a4>
Fri, 26 Jul 2013 11:49:12 +0000 (11:49 +0000)
not initializers.

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

gcc/testsuite/ChangeLog
gcc/testsuite/gcc.target/powerpc/ppc-vector-memcpy.c

index a95bc49..fb2ffa8 100644 (file)
@@ -1,3 +1,8 @@
+2013-07-26  David Edelsohn  <dje.gcc@gmail.com>
+
+       * gcc.target/powerpc/ppc-vector-memcpy.c: Test use of VMX for
+       memcpy not initializers.
+
 2013-07-26  Paolo Carlini  <paolo.carlini@oracle.com>
 
        PR c++/57101
index 797c407..7d4207f 100644 (file)
@@ -3,8 +3,12 @@
 /* { dg-options "-O -maltivec -mno-vsx" } */
 /* { dg-final { scan-assembler "lvx" } } */
 
+#include <string.h>
+
 void foo(void)
 {
-  int x[8] __attribute__((aligned(128))) = { 1, 1, 1, 1, 1, 1, 1, 1 };
-  bar (x);
+  extern int x[8] __attribute__((aligned(128)));
+  int y[8] __attribute__((aligned(128)));
+  memcpy (y, x, sizeof (x));
+  bar (y);
 }