cpp: #include <stdio.h>\n#include <omp.h>\n#include <stdlib.h>\n#define N 100\n#define C 16\n\nint main(){\n  int var[N];\n\n  for(int i=0; i<N; i++){\n    var[i]=0;\n  }\n\n  #pragma omp target map(tofrom:var[0:N]) device(0)\n  #pragma omp teams distribute parallel for simd safelen(C)\n  for (int i=C; i<N; i++){\n    var[i]=var[i-C]+1;\n  }\n\n  printf("%d\n",var[97]);\n\n  return 0;\n}\n
fortran: program DRB157_missingorderedsimd_orig_gpu_yes\n    use omp_lib\n    implicit none\n\n    integer :: var(100)\n    integer :: i\n\n    do i = 1, 100\n        var(i) = 1\n    end do\n\n    !$omp target map(tofrom:var) device(0)\n    !$omp teams distribute parallel do simd safelen(16)\n    do i = 17, 100\n        var(i) = var(i-16)+1\n    end do\n    !$omp end teams distribute parallel do simd\n    !$omp end target\n\n    print*,var(98)\nend program