summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorvictork <victork@138bc75d-0d04-0410-961f-82ee72b054a4>2008-08-04 17:25:13 +0000
committervictork <victork@138bc75d-0d04-0410-961f-82ee72b054a4>2008-08-04 17:25:13 +0000
commit0c04d3f5ef5ca379a6d9cec3555151269a4f5557 (patch)
treec518754e733bbad13a98da4b919f609567dfef90
parent7140793812a4f2bee4fe9064a0f71cbd002351ad (diff)
downloadppe42-gcc-0c04d3f5ef5ca379a6d9cec3555151269a4f5557.tar.gz
ppe42-gcc-0c04d3f5ef5ca379a6d9cec3555151269a4f5557.zip
2008-08-04 Victor Kaplansky <victork@il.ibm.com>
* gcc.dg/vect/vect-complex-5.c: New test. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@138643 138bc75d-0d04-0410-961f-82ee72b054a4
-rw-r--r--gcc/testsuite/ChangeLog4
-rw-r--r--gcc/testsuite/gcc.dg/vect/vect-complex-5.c45
2 files changed, 49 insertions, 0 deletions
diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog
index 2803cfedfed..2dafc220ec1 100644
--- a/gcc/testsuite/ChangeLog
+++ b/gcc/testsuite/ChangeLog
@@ -1,3 +1,7 @@
+2008-08-04 Victor Kaplansky <victork@il.ibm.com>
+
+ * gcc.dg/vect/vect-complex-5.c: New test.
+
2008-08-04 Simon Baldwin <simonb@google.com>
PR c++/36999
diff --git a/gcc/testsuite/gcc.dg/vect/vect-complex-5.c b/gcc/testsuite/gcc.dg/vect/vect-complex-5.c
new file mode 100644
index 00000000000..91eb1f54b3c
--- /dev/null
+++ b/gcc/testsuite/gcc.dg/vect/vect-complex-5.c
@@ -0,0 +1,45 @@
+/* { dg-require-effective-target vect_int } */
+
+#include <stdio.h>
+#include <stdarg.h>
+#include "tree-vect.h"
+
+#define N 16
+
+struct foostr {
+ _Complex short f1;
+ _Complex short f2;
+};
+
+_Complex short a1[64] __attribute__ ((__aligned__(16)));
+_Complex short a2[64] __attribute__ ((__aligned__(16)));
+_Complex short b1[64] __attribute__ ((__aligned__(16)));
+_Complex short b2[64] __attribute__ ((__aligned__(16)));
+struct foostr c[64] __attribute__ ((__aligned__(16)));
+
+__attribute__ ((noinline)) void
+foo (void)
+{
+ int i;
+
+ for (i = 0; i < N; i++)
+ {
+ c[i].f1 = a1[i] + b1[i];
+ c[i].f2 = a2[i] + b2[i];
+ }
+
+}
+
+int
+main (void)
+{
+ int i;
+ check_vect ();
+
+ foo ();
+
+ return 0;
+}
+
+/* { dg-final { scan-tree-dump-times "vectorizing stmts using SLP" 0 "vect" } } */
+/* { dg-final { cleanup-tree-dump "vect" } } */
OpenPOWER on IntegriCloud