===================================================================
@@ -1,3 +1,7 @@
+2015-12-08 James Norris <jnorris@codesourcery.com>
+
+ * testsuite/libgomp.oacc-fortran/kernels-map-1.f90: Add new test.
+
2015-12-08 Thomas Schwinge <thomas@codesourcery.com>
James Norris <jnorris@codesourcery.com>
===================================================================
@@ -1,9 +1,9 @@
-! Test the copy, copyin, copyout, pcopy, pcopyin, and pcopyout
+! Test the copy, copyin, copyout, pcopy, pcopyin, pcopyout, and pcreate
! clauses on kernels constructs.
program map
integer, parameter :: n = 20, c = 10
- integer :: i, a(n), b(n)
+ integer :: i, a(n), b(n), d(n)
a(:) = 0
b(:) = 0
@@ -88,6 +88,20 @@
!$acc end kernels
call check (a, b, n)
+
+ ! PRESENT_OR_CREATE
+
+ a(:) = 0
+
+ !$acc kernels pcopyout (a) pcreate (d)
+ !$acc loop
+ do i = 1, n
+ d(i) = i
+ a(i) = d(i)
+ end do
+ !$acc end kernels
+
+ call check (a, b, n)
end program map
subroutine check (a, b, n)