OpenMP-Validation-and-Verification / OpenMP_VV

OpenMP Offloading Validation & Verification Suite; Official repository. We have migrated from bitbucket!! For documentation, results, publication and presentations, please check out our website ->
https://crpl.cis.udel.edu/ompvvsollve/
Other
52 stars 18 forks source link

Nested 'Parallel Reduction' case #90

Open josemonsalve2 opened 4 years ago

josemonsalve2 commented 4 years ago

Directive and clause it applies to Parallel within parallel and reduction

Specification details From Mailing List: Is it a known problem?

int main()
{
  int t=-1;

#pragma omp target teams map(t)
{
  #pragma omp parallel reduction(+: t)
  {
    #pragma omp parallel reduction(+: t)
    {
      t = 1;
    }
  }
}
}
$ clang -fopenmp -fopenmp-targets=nvptx64-nvidia-cuda tmp.c
ptxas /tmp/thread_limit-984c26.s, line 1792; error   : Instruction 'vote' without '.sync' is not supported on .target sm_70 and higher from PTX ISA version 6.4
ptxas fatal   : Ptx assembly aborted due to errors
clang-11: error: ptxas command failed with exit code 255 (use -v to see invocation)
$ bin/clang -fopenmp -fopenmp-targets=nvptx64-nvidia-cuda tmp.c -Xopenmp-target -march=sm_60
ptxas /tmp/thread_limit-5cc9b6.s, line 1792; warning : Instruction 'vote' without '.sync' is deprecated since PTX ISA version 6.0 and will be discontinued in a future PTX ISA version

Kelvin Any other comments Reported by Kelvin Li

spophale commented 4 years ago

It compiles and runs fine on Summit with xlc, if that helps. Value of t is inconsistent across runs.

Rombur commented 4 years ago

For info, I have seen this error several times with different codes when using clang-9 but it works with clang-10. I can compile and run the test on Volta.

josemonsalve2 commented 4 years ago

Good to know @Rombur, I have yet to install LLVM10 in our testing systems, my understanding is that they are still in RC2? Anyway, we will make sure we have the test for any future regression testing.

Rombur commented 4 years ago

Yes, LLVM 10 is still in RC but LLVM 9 was not working for me so I had to do an early upgrade.

tmh97 commented 2 years ago

@spophale Compiles but provides inconsistent results for gcc and clang, fails at runtime with nvidia

spophale commented 2 years ago

What is the RT error msg ?

tmh97 commented 2 years ago

@spophale the compile time error is: warning: variable "t" was set but never used the runtime error is timeout: the monitored command dumped core