Files
clang-p2996/openmp/libomptarget/test/Inputs/basic_array.f90
Jan Leyonberg a0e3418bc8 [flang][OpenMP] Add fortran test with basic target region
This patch adds a test that uses a target region to set a scalar value. It also
adds rules in lit.cfg to handle fortran testing.

Reviewed By: jdoerfert

Differential Revision: https://reviews.llvm.org/D159216
2023-09-01 09:26:36 -04:00

8 lines
263 B
Fortran

subroutine increment_at(c_index, arr) bind(C, name="increment_at")
use ISO_C_BINDING
!$omp declare target
integer (C_INT), dimension(*), intent(inout) :: arr
integer (C_INT), value :: c_index
arr(c_index+1) = arr(c_index+1) + 1
end subroutine