Mercurial > hg > CbC > CbC_gcc
comparison gcc/testsuite/gcc.dg/vect/pr60092-2.c @ 111:04ced10e8804
gcc 7
author | kono |
---|---|
date | Fri, 27 Oct 2017 22:46:09 +0900 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
68:561a7518be6b | 111:04ced10e8804 |
---|---|
1 /* { dg-do compile } */ | |
2 /* { dg-require-effective-target vect_int } */ | |
3 | |
4 int posix_memalign(void **memptr, __SIZE_TYPE__ alignment, __SIZE_TYPE__ size); | |
5 void bar (int *); | |
6 | |
7 int *foo (int n) | |
8 { | |
9 int *p; | |
10 int *q; | |
11 void *tem; | |
12 if (posix_memalign (&tem, 256, n * sizeof (int)) != 0) | |
13 return (void *)0; | |
14 p = (int *)tem; | |
15 if (posix_memalign (&tem, 256, n * sizeof (int)) != 0) | |
16 return (void *)0; | |
17 q = (int *)tem; | |
18 bar (q); | |
19 int i; | |
20 for (i = 0; i < n; ++i) | |
21 p[i] = q[i] + q[i]; | |
22 return p; | |
23 } | |
24 | |
25 /* { dg-final { scan-tree-dump "LOOP VECTORIZED" "vect" } } */ | |
26 /* { dg-final { scan-tree-dump-not "Peeling for alignment will be applied" "vect" } } */ | |
27 /* { dg-final { scan-tree-dump-not "Vectorizing an unaligned access" "vect" } } */ |