gcc/libgomp/testsuite/libgomp.oacc-fortran/kernels-loop.f95
Thomas Schwinge ee2e7d5147 Nowadays, we use plain -fopenacc to enable OpenACC kernels processing
libgomp/
	* testsuite/libgomp.oacc-fortran/kernels-loop-2.f95: Adjust to
	-ftree-parallelize-loops/-fopenacc changes.
	* testsuite/libgomp.oacc-fortran/kernels-loop-data-2.f95:
	Likewise.
	* testsuite/libgomp.oacc-fortran/kernels-loop-data-enter-exit-2.f95:
	Likewise.
	* testsuite/libgomp.oacc-fortran/kernels-loop-data-enter-exit.f95:
	Likewise.
	* testsuite/libgomp.oacc-fortran/kernels-loop-data-update.f95:
	Likewise.
	* testsuite/libgomp.oacc-fortran/kernels-loop-data.f95: Likewise.
	* testsuite/libgomp.oacc-fortran/kernels-loop.f95: Likewise.

From-SVN: r234257
2016-03-16 14:10:20 +01:00

28 lines
484 B
Fortran

! { dg-do run }
program main
implicit none
integer, parameter :: n = 1024
integer, dimension (0:n-1) :: a, b, c
integer :: i, ii
do i = 0, n - 1
a(i) = i * 2
end do
do i = 0, n -1
b(i) = i * 4
end do
!$acc kernels copyin (a(0:n-1), b(0:n-1)) copyout (c(0:n-1))
do ii = 0, n - 1
c(ii) = a(ii) + b(ii)
end do
!$acc end kernels
do i = 0, n - 1
if (c(i) .ne. a(i) + b(i)) call abort
end do
end program main