comparison gcc/testsuite/c-c++-common/goacc/kernels-alias-8.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-additional-options "-O2" } */
2 /* { dg-additional-options "-fdump-tree-ealias-all" } */
3
4 typedef __SIZE_TYPE__ size_t;
5 extern void *acc_copyin (void *, size_t);
6
7 void
8 foo (int *a, size_t n)
9 {
10 int *p = (int *)acc_copyin (a, n);
11
12 #pragma acc kernels deviceptr (p) pcopy(a[0:n])
13 {
14 a = 0;
15 *p = 1;
16 }
17 }
18
19 /* Only the omp_data_i related loads should be annotated with cliques. */
20 /* { dg-final { scan-tree-dump-times "clique 1 base 1" 2 "ealias" } } */
21 /* { dg-final { scan-tree-dump-times "(?n)clique 1 base 0" 2 "ealias" } } */
22