FS#76196 - [nvidia-utils] doesn't install libnvidia-nvvm.so.4
Attached to Project:
Arch Linux
Opened by Brennan Shacklett (bps) - Thursday, 13 October 2022, 23:26 GMT
Last edited by Sven-Hendrik Haase (Svenstaro) - Wednesday, 19 October 2022, 16:40 GMT
Opened by Brennan Shacklett (bps) - Thursday, 13 October 2022, 23:26 GMT
Last edited by Sven-Hendrik Haase (Svenstaro) - Wednesday, 19 October 2022, 16:40 GMT
|
Details
Description:
I noticed that libnvidia-nvvm.so.4 is missing on my machine when trying to follow nvidia's guide on using link time optimization with NVRTC: https://docs.nvidia.com/cuda/nvrtc/index.html#example-lto While initially I thought this missing library should be provided by CUDA, it seems that it is actually provided by the nvidia driver itself. Unpacking the driver's run file (NVIDIA-Linux-x86_64-520.26.06.run) and checking html/installedcomponents.html contains: The NVVM Compiler library (<code class="filename">/usr/lib/libnvidia-nvvm.so.4.0.0</code>) is loaded by the CUDA driver to do JIT link-time-optimization.</p> Strangely, the run file itself only contains libnvidia-nvvm.so.520.56.06, so it isn't immediately clear to me how the .so.4 prefix is supposed to be derived, but perhaps there is something I'm missing given that installedcomponents.html corroborates the .so.4 naming convention. The NVRTC compiler specific tries to load libnvidia-nvvm.so.4 at runtime (shown with LD_DEBUG=libs), so just installing libnvidia-nvvm.so.520.56.06 would not work. Steps to reproduce: Install nvidia-utils, cuda, and then try to build and run the example program specified here: https://docs.nvidia.com/cuda/nvrtc/index.html#example-lto. You will get an error that the PTX compiler cannot be loaded, which can be traced back to failing to load this library. Copying libnvidia-nvvm.so.20.56.06 from the run file to /usr/lib/libnvidia-nvvm.so.4 fixes the issue. . |
This task depends upon
Closed by Sven-Hendrik Haase (Svenstaro)
Wednesday, 19 October 2022, 16:40 GMT
Reason for closing: Fixed
Wednesday, 19 October 2022, 16:40 GMT
Reason for closing: Fixed
# The NVVM Compiler library is loaded by the CUDA driver to do JIT link-time-optimization
install -Dm644 "libnvidia-nvvm.so.${pkgver}" "${pkgdir}/usr/lib/libnvidia-nvvm.so.${pkgver}"
❯ pacman -Ql nvidia-utils | grep nvvm
nvidia-utils /usr/lib/libnvidia-nvvm.so
nvidia-utils /usr/lib/libnvidia-nvvm.so.4
nvidia-utils /usr/lib/libnvidia-nvvm.so.520.56.06