summaryrefslogtreecommitdiffstats
path: root/Modules/FindCUDAToolkit.cmake
Commit message (Collapse)AuthorAgeFilesLines
* Help: Replace links with their permanent redirectsBrad King2023-02-171-1/+1
|
* FindCUDAToolkit: Replace broken links to NVIDIA documentationBrad King2023-02-171-3/+3
| | | | | | | | The cuFile API documentation has moved, so link to its new location. The nvGRAPH library has been removed, so link to a web archive copy. The NTVX library has a higher-level landing page.
* FindCUDAToolkit: Fix `nvrtc_builtins_static` library namePaul Taylor2023-02-061-1/+1
| | | | | | Update the change from commit 2a94c762ed (FindCUDAToolkit: Add support for CUDA::nvrtc_static, 2023-01-20, v3.26.0-rc1~55^2). The lib is named `libnvrtc-builtins_static.a`, not `libnvrtc_builtins_static.a`.
* FindCUDAToolkit: Add support for CUDA::nvrtc_staticRobert Maynard2023-01-201-1/+13
|
* FindCUDAToolkit: Support cross-compilation to sbsa-linuxRobert Maynard2023-01-111-18/+21
| | | | Fixes #24192
* FindCUDAToolkit: Handle CUDA::nvToolsExt not existingRobert Maynard2023-01-111-1/+1
|
* FindCUDAToolkit: Support the new `nvJitLink` library in CUDA 12Robert Maynard2022-12-121-0/+17
|
* FindCUDAToolkit: Ensure that paths provided have no symlinksRobert Maynard2022-11-301-7/+28
| | | | Fixes: #24188
* Merge topic 'find_cuda_toolkit_support_symlink_math_dirs'Brad King2022-11-231-3/+10
|\ | | | | | | | | | | | | | | 989d50d7fc FindCUDAToolkit: Support nvhpc splayed layouts without symlinks 207518b6e8 FindCUDAToolkit: Handle CUDAToolkit_TARGET_DIR dir being a symlink Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !7945
| * FindCUDAToolkit: Support nvhpc splayed layouts without symlinksRobert Maynard2022-11-221-2/+8
| |
| * FindCUDAToolkit: Handle CUDAToolkit_TARGET_DIR dir being a symlinkRobert Maynard2022-11-181-2/+3
| |
* | Merge topic 'FindCUDAToolkit_handle_nvptxcompiler_static_not_existing'Brad King2022-11-181-1/+3
|\ \ | |/ |/| | | | | | | | | c7ece269da FindCUDAToolkit: Handle toolkits that don't provide nvptxcompiler Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !7932
| * FindCUDAToolkit: Handle toolkits that don't provide nvptxcompilerRobert Maynard2022-11-171-1/+3
| | | | | | | | | | | | Some versions of the CUDA toolkit don't provide any static libraries, and therefore we need to handle that `nvptxcompiler_static` might not be found
* | FindCUDAToolkit: Support math_libs directory being a symlinkRobert Maynard2022-11-091-2/+2
|/ | | | Fixes #24140
* FindCUDAToolkit: Restore usage from multiple directoriesRobert Maynard2022-11-021-2/+4
| | | | Fixes #24119
* FindCUDAToolkit: Add nvptxcompiler_static dependency on Threads::ThreadsRobert Maynard2022-10-311-1/+2
|
* FindCUDAToolkit: cuFile_rdma_static needs to link to cuFile_staticRobert Maynard2022-10-121-1/+1
|
* Merge topic 'add_nvptx_compiler_to_findCUDAToolkit' into release-3.25Brad King2022-10-121-0/+20
|\ | | | | | | | | | | | | 01cfd0163d FindCUDAToolkit: Add support for the nvptx compiler library Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !7779
| * FindCUDAToolkit: Add support for the nvptx compiler libraryRobert Maynard2022-10-111-0/+20
| | | | | | | | Fixes #23892
* | FindCUDAToolkit: Add support for the cuFile libraryRobert Maynard2022-10-111-0/+25
|/
* Merge topic 'findCUDAToolkit_declare_deps_for_targets_once'Brad King2022-09-071-17/+20
|\ | | | | | | | | | | | | f0918fe505 FindCUDAToolkit: Correctly state cusolver and cublas dependencies Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !7633
| * FindCUDAToolkit: Correctly state cusolver and cublas dependenciesRobert Maynard2022-09-021-17/+20
| | | | | | | | Fixes #23920
* | Merge topic 'correct_cupti_search_paths'Craig Scott2022-08-261-1/+1
|\ \ | | | | | | | | | | | | | | | | | | 1f3c3589f1 FindCUDAToolkit: Search the cuda toolkit include path for cupti Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !7608
| * | FindCUDAToolkit: Search the cuda toolkit include path for cuptiRobert Maynard2022-08-241-1/+1
| | |
* | | FindCUDAToolkit: nvtx3 targetRaul Tambre2022-08-131-0/+32
|/ / | | | | | | | | | | | | | | | | | | | | | | | | | | nvtx3 is a header-only replacement for the previous shared library implementations. I implemented it as a separate target since while the header names match and ideally it should be API compatible, forcing its include directory into the old target would lengthen the include search path and could cause confusion or possible build differences for projects using multiple build systems. This keeps it explicit as a developer opt-in. Implements: #21377 Resolves: #23835
* | CUDAToolkit: Add include paths for CUDA::cuptiPeter Bell2022-04-261-7/+20
|/ | | | | | | | CUDA's cupti library has its headers in a seperate directory on a standard CUDA install, but `CUDA::cupti` only adds the default cuda include directory. Issue: #22761
* FindCUDAToolkit: Add missing cufftw_static targetRobert Maynard2022-03-211-1/+1
| | | | Fixes #23347
* CUDA: Generic all and all-major supportRaul Tambre2022-02-011-36/+41
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Commit 14d8a276 (CUDA: Support nvcc 11.5 new -arch=all|all-major flags, 2021-08-17) added all and all-major options to CUDA_ARCHITECTURES. These are fairly generic and likely to see real-world use by distributors. Thus it's desirable to support these also for Clang and older NVCC versions. The supported architectures are dependent on the toolkit version. We determine the toolkit version prior to compiler detection. For NVCC we get the version from the vendor identification output, but for Clang we need to invoke NVCC separately. The architecture information is mostly based on the Wikipedia list with the earliest supported version being CUDA 7.0. This could be documented and expanded in the future to allow projects to query CUDA toolkit version and architecture information. For Clang we additionally constrain based on its support. Additionally the architecture mismatch detection logic is fixed, improved and updated for generic support: * Commit 01428c55 (CUDA: Fail fast if CMAKE_CUDA_ARCHITECTURES doesn't work during detection, 2020-08-29) enabled CMAKE_CUDA_COMPILER_ID_REQUIRE_SUCCESS if CMAKE_CUDA_ARCHITECTURES is specified. This results in CMakeDetermineCompilerID.cmake printing the compiler error and our code for presenting the mismatch in a user-friendly way being useless. The custom logic seems preferable so go back to not enabling it. * Commit 14d8a276 (CUDA: Support nvcc 11.5 new -arch=all|all-major flags, 2021-08-17) tried to support CMP0054 but forgot to add x to the interpolated result. Thus the conditions would always evaluate to false. This is fixed as a byproduct of removing NVIDIA specific checks, improving the error message and replacing architectures_mode with a simpler architectures_explicit. Visual Studio support omits testing the flags during detection due to complexities in determining the toolkit version when using it. A long-term proper implementation would be #23161. Implements #22860.
* FindCUDAToolkit: Remove duplicated targets in docsGuo2022-01-241-3/+1
| | | | Also remove an unfinished sentence.
* Merge topic 'cudatoolkit_find_cufft_static_nocallback'Brad King2022-01-131-0/+4
|\ | | | | | | | | | | | | | | a4126d1c01 CUDAToolkit: Add CUDA::cufft_static_nocallback target Acked-by: Kitware Robot <kwrobot@kitware.com> Reviewed-by: Raul Tambre <raul@tambre.ee> Merge-request: !6856
| * CUDAToolkit: Add CUDA::cufft_static_nocallback targetRobert Maynard2022-01-121-0/+4
| | | | | | | | Fixes: #23098
* | FindCUDAToolkit: depend cublas on cublasLt for CUDA 11.0+Robert Maynard2022-01-121-0/+7
|/
* FindCUDAToolkit: Correct cusparse dependencies for 10.1, 11.2.2Robert Maynard2021-11-191-0/+17
|
* FindCUDAToolkit: Fix missing sibling include directory for math librariesSteven Hahn2021-10-051-0/+19
| | | | Fixes: #22706
* FindCUDAToolkit: Understand NVHPC versioned math library layoutRobert Maynard2021-07-281-0/+3
| | | | | | | | | | | The NVHPC packages bundle the CUDA math libraries in a sibling directory (`math_libs`) instead of in with the rest of the cuda libraries. Depending on the NVHPC package the math_libs folder can have versioned subdirectories, therefore we prefer finding the same versions as the CUDA Toolkit and falling back to the latest when not possible.
* Merge topic 'FindCUDAToolkit-doc-version'Brad King2021-07-081-3/+8
|\ | | | | | | | | | | | | 266fc8ada5 FindCUDAToolkit: Properly document the version support Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !6320
| * FindCUDAToolkit: Properly document the version supportRobert Maynard2021-07-071-3/+8
| |
* | Merge topic 'correct_cuda_toolkit_version_typo'Brad King2021-07-071-1/+1
|\ \ | | | | | | | | | | | | | | | | | | | | | 0d54276c82 Correct CUDAToolkit_VERSION_MINOR variable name typo Acked-by: Kitware Robot <kwrobot@kitware.com> Reviewed-by: Raul Tambre <raul@tambre.ee> Merge-request: !6311
| * | Correct CUDAToolkit_VERSION_MINOR variable name typoRobert Maynard2021-07-061-1/+1
| |/
* | FindCUDATookit: Fix ordering of libraries in imported targetsDan Ibanez2021-07-011-2/+2
|/ | | | | | | | | | Before this a downstream code linking to `CUDA::cusparse_static` and `CUDA::curand_static` would get a link line with `libcusparse_static.a`, then `libculibos.a`, then `libcurand_static.a`. Use `IMPORTED_LOCATION` to tell CMake about the proper dependency ordering where `libculibos.a` comes last, because the other two libraries depend on `libculibos.a`. Fixes: #22365
* CUDA: improve regex for CUDA Toolkit root from nvcc verbose outputRobert Maynard2021-05-061-1/+1
| | | | | | | | | | | | The original regular expression was greedy and would match any environment variable ending with `TOP` (like `DESKTOP`). This is an issue on windows where `nvcc -v` would output all environment variables before the compiler's verbose output. To resolve this issue we use a tighter match algorithm that looks for `#$ TOP=` instead of `TOP=`. Fixes: #22158
* CUDA: Capture all nvcc output when extracting toolkit rootBrad King2021-02-121-3/+4
| | | | | | | | | Since commit fb2afef620 (CUDA: Support nvcc symlinking to ccache, 2021-01-07) and commit 3cef91a321 (CUDA: Always extract CUDA Toolkit root from nvcc verbose output, 2021-02-03) we always run the command `nvcc -v __cmake_determine_cuda` to look for the toolkit root in its stderr. On Windows, that command may print to stdout instead, so capture that as well.
* Merge topic 'findcudatoolkit_handle_cuda_compiler_without_enabled_lang'Brad King2021-02-101-0/+1
|\ | | | | | | | | | | | | | | | | cd89d1c328 FindCUDAToolkit: Robust version checks when CUDA lang is not enabled Acked-by: Kitware Robot <kwrobot@kitware.com> Reviewed-by: Raul Tambre <raul@tambre.ee> Tested-by: Raul Tambre <raul@tambre.ee> Merge-request: !5787
| * FindCUDAToolkit: Robust version checks when CUDA lang is not enabledRobert Maynard2021-02-091-0/+1
| | | | | | | | | | | | Previously if you set `CMAKE_CUDA_COMPILER` but hadn't enabled the CUDA language, FindCUDAToolkit would not correctly compute the version information.
* | CUDA: Always extract CUDA Toolkit root from nvcc verbose outputRobert Maynard2021-02-081-13/+12
|/ | | | | | | | | | | | Fixes #21750, #21763 Given that NVCC can be provided by multiple different sources (NVIDIA HPC SDK, CUDA Toolkit, distro) each of which has a different layout, we need to extract the CUDA toolkit root from the compiler itself, allowing us to support numerious different scattered toolkit layouts. The NVIDIA HPC SDK specifically ships two copies of nvcc one in `compilers/bin/` and one in `cuda/bin`. Thus when using `compilers/bin/nvcc` the Toolkit root logic fails.
* Merge topic 'findcudatoolkit_env_path'Brad King2021-02-031-1/+1
|\ | | | | | | | | | | | | | | 4ea6d3c3ae FindCUDAToolkit: Restore use of CUDA_PATH environment variable Acked-by: Kitware Robot <kwrobot@kitware.com> Acked-by: Raul Tambre <raul@tambre.ee> Merge-request: !5761
| * FindCUDAToolkit: Restore use of CUDA_PATH environment variableRobert Maynard2021-02-031-1/+1
| | | | | | | | | | | | | | | | Refactoring in commit 7cc815a2a6 (CUDAToolkit: Detect CUDA SDK that don't have nvcc, 2020-07-24, v3.19.0-rc1~366^2) accidentally broke use of the `CUDA_PATH` environment variable. Fixes: #21740
* | CUDA: Support nvcc symlinking to ccacheRong Ou2021-01-111-1/+13
| | | | | | | | | | | | | | Invoke `nvcc -v` to find the real CUDA bin directory. This is needed if `nvcc` is a symlink to `ccache` or `colornvcc`. Fixes: #21177
* | Help: Add `.. versionadded` directives to module docsNikita Nemkin2020-12-021-0/+5
|/ | | | Issue: #19715
* CUDA: Enable support on QNXjanbernloehr2020-11-021-1/+3
| | | | | | | | | | | This fixes the following two issues with the CUDA support on QNX: * cuda target name is not derived correctly (should be `aarch64-qnx`). * linking `cudart` must not be linked against `rt`, `dl`, `pthread`. This enables to use cmake's native cuda support on QNX. Fixes: #21381