Mercurial > hg > CbC > CbC_gcc
view gcc/testsuite/gcc.dg/vect/pr60092-2.c @ 131:84e7813d76e9
gcc-8.2
author | mir3636 |
---|---|
date | Thu, 25 Oct 2018 07:37:49 +0900 |
parents | 04ced10e8804 |
children |
line wrap: on
line source
/* { dg-do compile } */ /* { dg-require-effective-target vect_int } */ int posix_memalign(void **memptr, __SIZE_TYPE__ alignment, __SIZE_TYPE__ size); void bar (int *); int *foo (int n) { int *p; int *q; void *tem; if (posix_memalign (&tem, 256, n * sizeof (int)) != 0) return (void *)0; p = (int *)tem; if (posix_memalign (&tem, 256, n * sizeof (int)) != 0) return (void *)0; q = (int *)tem; bar (q); int i; for (i = 0; i < n; ++i) p[i] = q[i] + q[i]; return p; } /* { dg-final { scan-tree-dump "LOOP VECTORIZED" "vect" } } */ /* { dg-final { scan-tree-dump-not "Peeling for alignment will be applied" "vect" } } */ /* { dg-final { scan-tree-dump-not "Vectorizing an unaligned access" "vect" } } */