aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorDorit Nuzman <dorit@il.ibm.com>2007-08-19 09:32:22 +0000
committerDorit Nuzman <dorit@gcc.gnu.org>2007-08-19 09:32:22 +0000
commit66d229b83597da5a73035cd2e13b7d5dd3a1d3d2 (patch)
treed4fb3401d356ae553c84bf84bf7b416d4b6de771 /gcc
parent500f8f7b5fcd927a28d69c1af2427f4225e56a15 (diff)
downloadgcc-66d229b83597da5a73035cd2e13b7d5dd3a1d3d2.zip
gcc-66d229b83597da5a73035cd2e13b7d5dd3a1d3d2.tar.gz
gcc-66d229b83597da5a73035cd2e13b7d5dd3a1d3d2.tar.bz2
pr20122.c: Fix test (now vectorized, with versioning for aliasing).
* testsuite/gcc.dg/vect/pr20122.c: Fix test (now vectorized, with versioning for aliasing). * testsuite/gcc.dg/vect/vect-35.c: Likewise. * testsuite/gcc.dg/vect/vect-iv-6.c: Fix test for vect_no_align targets. * testsuite/gcc.dg/vect/vect-multitypes-11.c: Likewise. From-SVN: r127621
Diffstat (limited to 'gcc')
-rw-r--r--gcc/testsuite/ChangeLog9
-rw-r--r--gcc/testsuite/gcc.dg/vect/pr20122.c10
-rw-r--r--gcc/testsuite/gcc.dg/vect/vect-35.c10
-rw-r--r--gcc/testsuite/gcc.dg/vect/vect-iv-6.c5
-rw-r--r--gcc/testsuite/gcc.dg/vect/vect-multitypes-11.c1
5 files changed, 23 insertions, 12 deletions
diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog
index 3e5ff06..61f0352 100644
--- a/gcc/testsuite/ChangeLog
+++ b/gcc/testsuite/ChangeLog
@@ -1,3 +1,12 @@
+2007-08-19 Dorit Nuzman <dorit@il.ibm.com>
+
+ * testsuite/gcc.dg/vect/pr20122.c: Fix test (now vectorized, with
+ versioning for aliasing).
+ * testsuite/gcc.dg/vect/vect-35.c: Likewise.
+
+ * testsuite/gcc.dg/vect/vect-iv-6.c: Fix test for vect_no_align targets.
+ * testsuite/gcc.dg/vect/vect-multitypes-11.c: Likewise.
+
2007-08-18 Tom Tromey <tromey@redhat.com>
PR preprocessor/32974:
diff --git a/gcc/testsuite/gcc.dg/vect/pr20122.c b/gcc/testsuite/gcc.dg/vect/pr20122.c
index 4c09eec..05948c7 100644
--- a/gcc/testsuite/gcc.dg/vect/pr20122.c
+++ b/gcc/testsuite/gcc.dg/vect/pr20122.c
@@ -7,7 +7,8 @@ short Kernshort[24] __attribute__ ((__aligned__(16)));
static void VecBug(short Kernel[8][24]) __attribute__((noinline));
static void VecBug2(short Kernel[8][24]) __attribute__((noinline));
-/* Not vectorizable: Kernel may alias Kernshort - a global array. */
+/* Kernel may alias Kernshort - a global array.
+ Use versioning for aliasing. */
static void VecBug(short Kernel[8][24])
{
int k,i;
@@ -48,7 +49,8 @@ int main (int argc, char **argv)
return 0;
}
-
-/* { dg-final { scan-tree-dump-times "vectorized 1 loops" 2 "vect" } } */
-/* { dg-final { scan-tree-dump-times "Alignment of access forced using versioning" 1 "vect" { target vect_no_align } } } */
+/* The loops in VecBug and VecBug2 require versioning for alignment.
+ The loop in main is aligned. */
+/* { dg-final { scan-tree-dump-times "vectorized 1 loops" 3 "vect" } } */
+/* { dg-final { scan-tree-dump-times "Alignment of access forced using versioning" 2 "vect" { target vect_no_align } } } */
/* { dg-final { cleanup-tree-dump "vect" } } */
diff --git a/gcc/testsuite/gcc.dg/vect/vect-35.c b/gcc/testsuite/gcc.dg/vect/vect-35.c
index ef36d1c..f4392cd 100644
--- a/gcc/testsuite/gcc.dg/vect/vect-35.c
+++ b/gcc/testsuite/gcc.dg/vect/vect-35.c
@@ -8,8 +8,8 @@
int main1 ()
{
union {
- char a[N] __attribute__ ((__aligned__(16)));
- char b[N] __attribute__ ((__aligned__(16)));
+ unsigned char a[N] __attribute__ ((__aligned__(16)));
+ unsigned char b[N] __attribute__ ((__aligned__(16)));
} s;
int i;
@@ -19,8 +19,8 @@ int main1 ()
s.b[i] = 3*i;
}
- /* Can't vectorize - dependence analysis fails cause s.a and s.b may
- overlap. */
+ /* Dependence analysis fails cause s.a and s.b may overlap.
+ Use runtime aliasing test with versioning. */
for (i = 0; i < N; i++)
{
s.a[i] = s.b[i] + 1;
@@ -44,6 +44,6 @@ int main (void)
}
-/* { dg-final { scan-tree-dump-times "vectorized 1 loops" 1 "vect" { xfail *-*-* } } } */
+/* { dg-final { scan-tree-dump-times "vectorized 1 loops" 1 "vect" } } */
/* { dg-final { scan-tree-dump-times "can't determine dependence between" 1 "vect" } } */
/* { dg-final { cleanup-tree-dump "vect" } } */
diff --git a/gcc/testsuite/gcc.dg/vect/vect-iv-6.c b/gcc/testsuite/gcc.dg/vect/vect-iv-6.c
index 3c301eb..6f02575 100644
--- a/gcc/testsuite/gcc.dg/vect/vect-iv-6.c
+++ b/gcc/testsuite/gcc.dg/vect/vect-iv-6.c
@@ -17,7 +17,8 @@ int main1 (int X)
by the loop-header phi (as opposed to the other uses of k that are
defined in the loop), in which case we exercise the fact that we
reuse the same vector def-use-cycle for both uses.
- Peeling to align the store is also applied. */
+ Peeling to align the store is also applied. This peeling also aligns
+ the load (as they have the same misalignment). */
do {
arr2[i+1] = 2*k;
@@ -45,5 +46,5 @@ int main (void)
return main1 (3);
}
-/* { dg-final { scan-tree-dump-times "vectorized 1 loops" 1 "vect" { xfail vect_no_align } } } */
+/* { dg-final { scan-tree-dump-times "vectorized 1 loops" 1 "vect" } } */
/* { dg-final { cleanup-tree-dump "vect" } } */
diff --git a/gcc/testsuite/gcc.dg/vect/vect-multitypes-11.c b/gcc/testsuite/gcc.dg/vect/vect-multitypes-11.c
index 26bba0b..81b2003 100644
--- a/gcc/testsuite/gcc.dg/vect/vect-multitypes-11.c
+++ b/gcc/testsuite/gcc.dg/vect/vect-multitypes-11.c
@@ -40,6 +40,5 @@ int main (void)
/* { dg-final { scan-tree-dump-times "vectorized 1 loops" 2 "vect" { target vect_unpack } } } */
/* { dg-final { scan-tree-dump-times "vectorized 1 loops" 1 "vect" { target { ! vect_unpack } } } } */
-/* { dg-final { scan-tree-dump-times "Alignment of access forced using peeling" 1 "vect" { target { vect_no_align && vect_unpack } } } } */
/* { dg-final { cleanup-tree-dump "vect" } } */