This is the mail archive of the
mailing list for the GCC project.
Re: [patch] vectorizer testsuite: add alignment checks
- From: Dorit Naishlos <DORIT at il dot ibm dot com>
- To: Eric Botcazou <ebotcazou at libertysurf dot fr>
- Cc: gcc-patches at gcc dot gnu dot org, Richard Henderson <rth at redhat dot com>
- Date: Sun, 16 Jan 2005 13:54:55 +0200
- Subject: Re: [patch] vectorizer testsuite: add alignment checks
> Maybe related to the size of the vector type.
> Can I xfail it on SPARC?
could xfail on SPARC,
or create a new target keyword "vecsize_more_than_64byte", and expect the
peeling to take place only for these targets,
or change the testcase as follows so that it will be also misaligned for
RCS file: /cvs/gcc/gcc/gcc/testsuite/gcc.dg/vect/vect-66.c,v
retrieving revision 1.6
diff -u -3 -p -r1.6 vect-66.c
--- vect-66.c 9 Jan 2005 17:30:23 -0000 1.6
+++ vect-66.c 16 Jan 2005 11:51:10 -0000
@@ -52,7 +52,7 @@ int main1 ()
for (j = 0; j < 4; j++)
- ic[j] = 5;
+ ic[j+1] = 5;
@@ -61,7 +61,7 @@ int main1 ()
for (j = 0; j < 4; j++)
- if (ic[j] != 5)
+ if (ic[j+1] != 5)
(I tested it on powerpc-darwin and i686-pc-linux-gnu).
I think I prefer the last option, but either is fine with me.
Eric Botcazou <email@example.com> wrote on 15/01/2005 14:47:15:
> > Sometimes when an access is not guaranteed to be aligned the vectorizer
> > performs loop peeling to force the alignment of the access.
> > of such accesses therefore does not require misalignment support, so
> > are not reported along with the above. To detect these we match the
> > "Alignment of access forced using peeling". This check was not added to
> > testcases in which accesses are trivially aligned (e.g. in which all
> > accesses are of user-defined types with sufficient alignment
> One problem on SPARC 32-bit and 64-bit:
> FAIL: gcc.dg/vect/vect-66.c scan-tree-dump-times Alignment of access
> using peeling 1
> We don't need loop peeling to vectorize the third loop:
> loop at vect-66.c:17: if (ivtmp.20_83 < 2) goto <L72>; else goto <L3>;
> loop at vect-66.c:17: LOOP VECTORIZED.
> loop at vect-66.c:28: not vectorized: bad loop form. multiple exits.
> loop at vect-66.c:36: if (ivtmp.28_69 < 2) goto <L78>; else goto <L17>;
> loop at vect-66.c:36: LOOP VECTORIZED.
> loop at vect-66.c:44: not vectorized: bad loop form. multiple exits.
> loop at vect-66.c:52: if (ivtmp.36_13 < 2) goto <L84>; else goto <L31>;
> loop at vect-66.c:52: LOOP VECTORIZED.
> loop at vect-66.c:63: not vectorized: bad loop form. multiple exits.
> Maybe related to the size of the vector type. Can I xfail it on SPARC?
> Eric Botcazou