[llvm-bugs] [Bug 47972] New: Trunk - Runtime kernel crash on simple code

via llvm-bugs llvm-bugs at lists.llvm.org
Mon Oct 26 06:45:29 PDT 2020


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

            Bug ID: 47972
           Summary: Trunk - Runtime kernel crash on simple code
           Product: OpenMP
           Version: unspecified
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: release blocker
          Priority: P
         Component: Runtime Library
          Assignee: unassignedbugs at nondot.org
          Reporter: josem at udel.edu
                CC: llvm-bugs at lists.llvm.org

Hi everyone, 

When compiling the simplest code on OMP offloading on the latest trunk commit
cae4067, the kernel breaks:

int main() {
  int x_spmd;
  #pragma omp target map(x_spmd)
    x_spmd++;
  return 0;
}

clang  -fopenmp -fopenmp-targets=nvptx64 simple.c -o simple

I have tried 2 machines already and I cannot seem to find the problem. 

The LIBOMPTARGET_DEGUB=1 output

Libomptarget --> Init target library!
Libomptarget --> Loading RTLs...
Libomptarget --> Loading library 'libomptarget.rtl.ppc64.so'...
Libomptarget --> Unable to load library 'libomptarget.rtl.ppc64.so':
libomptarget.rtl.ppc64.so: cannot open shared object file: No such file or
directory!
Libomptarget --> Loading library 'libomptarget.rtl.x86_64.so'...
Libomptarget --> Successfully loaded library 'libomptarget.rtl.x86_64.so'!
Libomptarget --> Registering RTL libomptarget.rtl.x86_64.so supporting 4
devices!
Libomptarget --> Loading library 'libomptarget.rtl.cuda.so'...
Target CUDA RTL --> Start initializing CUDA
Libomptarget --> Successfully loaded library 'libomptarget.rtl.cuda.so'!
Libomptarget --> Registering RTL libomptarget.rtl.cuda.so supporting 4 devices!
Libomptarget --> Loading library 'libomptarget.rtl.aarch64.so'...
Libomptarget --> Unable to load library 'libomptarget.rtl.aarch64.so':
libomptarget.rtl.aarch64.so: cannot open shared object file: No such file or
directory!
Libomptarget --> Loading library 'libomptarget.rtl.ve.so'...
Libomptarget --> Unable to load library 'libomptarget.rtl.ve.so':
libomptarget.rtl.ve.so: cannot open shared object file: No such file or
directory!
Libomptarget --> Loading library 'libomptarget.rtl.amdgpu.so'...
Libomptarget --> Unable to load library 'libomptarget.rtl.amdgpu.so':
libomptarget.rtl.amdgpu.so: cannot open shared object file: No such file or
directory!
Libomptarget --> RTLs loaded!
Libomptarget --> Image 0x0000000000400850 is NOT compatible with RTL
libomptarget.rtl.x86_64.so!
Libomptarget --> Image 0x0000000000400850 is compatible with RTL
libomptarget.rtl.cuda.so!
Libomptarget --> RTL 0x0000000001df80e0 has index 0!
Libomptarget --> Registering image 0x0000000000400850 with RTL
libomptarget.rtl.cuda.so!
Libomptarget --> Done registering entries!
Libomptarget --> Call to omp_get_num_devices returning 4
Libomptarget --> Default TARGET OFFLOAD policy is now mandatory (devices were
found)
Libomptarget --> Entering target region with entry point 0x0000000000400800 and
device Id -1
Libomptarget --> Checking whether device 0 is ready.
Libomptarget --> Is the device 0 (local ID 0) initialized? 0
Target CUDA RTL --> Init requires flags to 1
Target CUDA RTL --> Getting device 0
Target CUDA RTL --> The primary context is inactive, set its flags to
CU_CTX_SCHED_BLOCKING_SYNC
Target CUDA RTL --> Max CUDA blocks per grid 2147483647 exceeds the hard team
limit 65536, capping at the hard limit
Target CUDA RTL --> Using 1024 CUDA threads per block
Target CUDA RTL --> Using warp size 32
Target CUDA RTL --> Device supports up to 65536 CUDA blocks and 1024 threads
with a warp size of 32
Target CUDA RTL --> Default number of teams set according to library's default
128
Target CUDA RTL --> Default number of threads set according to library's
default 128
Libomptarget --> Device 0 is ready to use.
Target CUDA RTL --> Load data from image 0x0000000000400850
Target CUDA RTL --> Error returned from cuModuleLoadDataEx
Target CUDA RTL --> CUDA error is: device kernel image is invalid
Libomptarget --> Unable to generate entries table for device id 0.
Libomptarget --> Failed to init globals on device 0
Libomptarget --> Failed to get device 0 ready
Libomptarget error: run with env LIBOMPTARGET_INFO>1 to dump host-targetpointer
maps
Libomptarget fatal error 1: failure of target construct while offloading is
mandatory


Thanks!

Jose

-- 
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20201026/15b33896/attachment.html>


More information about the llvm-bugs mailing list