flang/test/Semantics/OpenMP/simd02.f90
raw| 1 | ! RUN: %python %S/../test_errors.py %s %flang -fopenmp |
| 2 | |
| 3 | ! OpenMP Version 4.5 |
| 4 | ! 2.8.1 simd Construct |
| 5 | ! Semantic error for correct test case |
| 6 | |
| 7 | program omp_simd |
| 8 | integer i, j, k |
| 9 | integer, allocatable :: a(:) |
| 10 | |
| 11 | allocate(a(10)) |
| 12 | |
| 13 | !$omp simd aligned(a) |
| 14 | do i = 1, 10 |
| 15 | a(i) = i |
| 16 | end do |
| 17 | !$omp end simd |
| 18 | |
| 19 | print *, a |
| 20 | |
| 21 | end program omp_simd |