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
Fix warning with -Wsign-compare -Wsystem-headers
[official-gcc.git]
/
libgomp
/
testsuite
/
libgomp.oacc-fortran
/
vector-routine.f90
blob
1edcee48677e2b9633c2d7e2124d0def66d40a57
1
! { dg-do run }
2
3
module
param
4
integer
,
parameter
::
N
=
32
5
end module
param
6
7
program
main
8
use
param
9
integer
::
i
10
integer
::
a
(
N
)
11
12
do
i
=
1
,
N
13
a
(
i
) =
i
14
end do
15
16
!$acc parallel copy (a)
17
!$acc loop worker
18
do
i
=
1
,
N
19
call
vector
(
a
)
20
end do
21
!$acc end parallel
22
23
do
i
=
1
,
N
24
if
(
a
(
i
) .
ne
.
0
)
call
abort
25
end do
26
27
contains
28
29
subroutine
vector
(
a
)
30
!$acc routine vector
31
integer
,
intent
(
inout
) ::
a
(
N
)
32
integer
::
i
33
34
!$acc loop vector
35
do
i
=
1
,
N
36
a
(
i
) =
a
(
i
) -
a
(
i
)
37
end do
38
39
end subroutine
vector
40
41
end program
main