Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix sanity checks for Clang 11 when built with NVPTX support #2782

Closed
zdemat opened this issue Sep 5, 2022 · 0 comments · Fixed by #2783
Closed

fix sanity checks for Clang 11 when built with NVPTX support #2782

zdemat opened this issue Sep 5, 2022 · 0 comments · Fixed by #2783
Labels
Milestone

Comments

@zdemat
Copy link

zdemat commented Sep 5, 2022

Clang creates the following libomptarget*nvptx*.bc according to its version (11, 12, 13). The current sanity check is handling wrongly 11.0.1 case.

# Clang 11.0.1
libomptarget-nvptx-sm_70.bc

libomptarget-nvptx.a
libomptarget.rtl.x86_64.so
libomptarget.so
libomptarget.rtl.cuda.so

# Clang 12.0.1
libomptarget-nvptx-cuda_80-sm_70.bc
libomptarget-nvptx-cuda_90-sm_70.bc
libomptarget-nvptx-cuda_91-sm_70.bc
libomptarget-nvptx-cuda_92-sm_70.bc
libomptarget-nvptx-cuda_100-sm_70.bc
libomptarget-nvptx-cuda_101-sm_70.bc
libomptarget-nvptx-cuda_102-sm_70.bc
libomptarget-nvptx-cuda_110-sm_70.bc
libomptarget-nvptx-cuda_111-sm_70.bc
libomptarget-nvptx-cuda_112-sm_70.bc

libomptarget.rtl.x86_64.so
libomptarget.so
libomptarget.rtl.cuda.so
libomptarget.so.12

# Clang 13.0.1
libomptarget-amdgcn-gfx700.bc
libomptarget-amdgcn-gfx701.bc
libomptarget-amdgcn-gfx801.bc
libomptarget-amdgcn-gfx803.bc
libomptarget-amdgcn-gfx900.bc
libomptarget-amdgcn-gfx902.bc
libomptarget-amdgcn-gfx906.bc
libomptarget-amdgcn-gfx908.bc

libomptarget-new-nvptx-sm_70.bc
libomptarget-nvptx-sm_70.bc

libomptarget.rtl.x86_64.so
libomptarget.so
libomptarget.rtl.cuda.so
libomptarget.rtl.amdgpu.so

I think the behavior when there is CUDA version included is typical only for v12 whereas in the current test it is applied on v11 too.

# clang.py (develop)

if LooseVersion('11.0') < LooseVersion(self.version) < LooseVersion('13.0'):
    custom_paths['files'].extend(["lib/libomptarget-nvptx-cuda_%s-sm_%s.bc" % (x, y)
                                 for x in CUDA_TOOLKIT_SUPPORT for y in cuda_cc])
else:
    custom_paths['files'].extend(["lib/libomptarget-nvptx-sm_%s.bc" % cc
                                 for cc in cuda_cc])

I was building on x86_64 with V100.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants