Issue |
159762
|
Summary |
[OpenMP] nvptx64-nvidia-cuda device library ignores `LLVM_LIBDIR_SUFFIX`
|
Labels |
|
Assignees |
|
Reporter |
tuliom
|
Since the migration of the device libraries in #136729, we started seeing an unexpected behavior while building the nvptx64-nvidia-cuda device library.
The library does get built, but it the installation ignores the value from `-DLLVM_LIBDIR_SUFFIX=64`.
I investigated this a bit and the earliest point where `LLVM_LIBDIR_SUFFIX` is erased is the following.
Notice also the warning messages about LLVM and Clang not being found:
```
-- Detecting CXX compiler ABI info - failed
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Could NOT find LLVM (missing: LLVM_DIR)
-- Could NOT find Clang (missing: Clang_DIR)
CMake Warning at CMakeLists.txt:94 (message):
debug-tm20 OPENMP_INSTALL_LIBDIR=
CMake Warning at CMakeLists.txt:95 (message):
debug-tm20
LLVM_LIBRARY_OUTPUT_INTDIR=/builddir/build/BUILD/llvm-22.0.0_pre20250909.g6a726e9a4d3d05-build/llvm-project-6a726e9a4d3d05f9aecf366fb6488d63135f04f3/llvm/redhat-linux-build/runtimes/runtimes-nvptx64-nvidia-cuda-bins/lib
CMake Warning at CMakeLists.txt:96 (message):
debug-tm20 LLVM_LIBDIR_SUFFIX=
-- Performing Test CXX_SUPPORTS_UNWINDLIB_EQ_NONE_FLAG
-- Performing Test CXX_SUPPORTS_UNWINDLIB_EQ_NONE_FLAG - Failed
-- Performing Test CXX_SUPPORTS_NOSTDLIBXX_FLAG
-- Performing Test CXX_SUPPORTS_NOSTDLIBXX_FLAG - Failed
-- Performing Test CXX_SUPPORTS_NOSTDINCXX_FLAG
-- Performing Test CXX_SUPPORTS_NOSTDINCXX_FLAG - Failed
CMake Warning (dev) at /usr/share/cmake/Modules/GNUInstallDirs.cmake:253 (message):
Unable to determine default CMAKE_INSTALL_LIBDIR directory because no
target architecture is known. Please enable at least one language before
including GNUInstallDirs.
Call Stack (most recent call first):
/builddir/build/BUILD/llvm-22.0.0_pre20250909.g6a726e9a4d3d05-build/llvm-project-6a726e9a4d3d05f9aecf366fb6488d63135f04f3/llvm/cmake/modules/AddLLVM.cmake:1 (include)
CMakeLists.txt:202 (include)
This warning is for project developers. Use -Wno-dev to suppress it.
```
When setting `-DRUNTIMES_nvptx64-nvidia-cuda_LLVM_LIBDIR_SUFFIX=64` behavior does not reproduce, although the warnings about not finding LLVM and Clang are still there. A full build log is available at:
[builder-live.log.gz](https://github.com/user-attachments/files/22426569/builder-live.log.gz)
The amdgcn-amd-amdhsa library does not show the same issue after applying #159758 .
_______________________________________________
llvm-bugs mailing list
llvm-bugs@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs