brintos

brintos / llvm-project-archived public Read only

0
0
Text · 639 B · 7c3759a Raw
34 lines · plain
1! RUN: %python %S/../test_errors.py %s %flang -fopenmp2! OpenMP Version 4.53! 2.15.4.1 copyin Clause4! A list item that appears in a copyin clause must be threadprivate.5! Named variables appearing in a threadprivate common block may be specified6! It is not necessary to specify the whole common block.7 8program omp_copyin9 10  integer :: a(10), b(10)11  common /cmn/ j, k12 13  !$omp threadprivate(/cmn/)14 15  j = 2016  k = 1017 18  !$omp parallel copyin(/cmn/)19  a(:5) = k20  b(:5) = j21  !$omp end parallel22 23  j = j + k24  k = k * j25 26  !$omp parallel copyin(j, k)27  a(6:) = j28  b(6:) = k29  !$omp end parallel30 31  print *, a, b32 33end program omp_copyin34