https://bugs.llvm.org/show_bug.cgi?id=49940

            Bug ID: 49940
           Summary: Race condition in libomptarget
           Product: OpenMP
           Version: unspecified
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: normal
          Priority: P
         Component: Runtime Library
          Assignee: [email protected]
          Reporter: [email protected]
                CC: [email protected]

The test "llvm-project/openmp/libomptarget/test/offloading/bug49334.cpp" fails
aleatory with both cuda and x86_64 plugins, most probably because of a race
condition within the device-agnostic part of libomptarget. This test is
implementing a block-based matrix multiplication that has the particularity to
create multiple asynchronous offloaded kernels (omp target nowait) that can be
executed in parallel (thus the race condition).

The issue can be reproduced by executing the test multiple times: 

- For CUDA plugin
clang++ -O3 -fopenmp -fopenmp-targets=nvptx64-nvidia-cuda
./llvm-project/openmp/libomptarget/test/offloading/bug49334.cpp -o
blockmatmul-gpu
for i in {1..100}; do ./blockmatmul-gpu || break; done

- For x86 plugin 
clang++ -O3 -fopenmp -fopenmp-targets=x86_64-pc-linux-gnu
./llvm-project/openmp/libomptarget/test/offloading/bug49334.cpp -o
blockmatmul-cpu
for i in {1..100}; do ./blockmatmul-cpu || break; done

The issue happens with the every recent versions of Clang (current development
version, v12.x, v11.x)

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
llvm-bugs mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs

Reply via email to