repo.or.cz
/
official-gcc.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
Rebase.
[official-gcc.git]
/
libgomp
/
testsuite
/
libgomp.c
/
target-8.c
blob
350845753244b4f7372050b1a6f804b84617eaa5
1
/* { dg-do run } */
2
/* { dg-options "-fopenmp" } */
3
4
void
5
foo
(
int
*
p
)
6
{
7
int
i
;
8
#pragma omp parallel
9
#pragma omp single
10
#pragma omp target teams distribute parallel for map(p[0:24])
11
for
(
i
=
0
;
i
<
24
;
i
++)
12
p
[
i
] =
p
[
i
] +
1
;
13
}
14
15
int
16
main
()
17
{
18
int
p
[
24
],
i
;
19
for
(
i
=
0
;
i
<
24
;
i
++)
20
p
[
i
] =
i
;
21
foo
(
p
);
22
for
(
i
=
0
;
i
<
24
;
i
++)
23
if
(
p
[
i
] !=
i
+
1
)
24
__builtin_abort
();
25
return
0
;
26
}