summaryrefslogtreecommitdiffstats
path: root/Modules/Compiler/Clang-CUDA.cmake
Commit message (Collapse)AuthorAgeFilesLines
* Clang/CUDA: Restore needed references to implicit link variablesRaul Tambre2021-02-241-2/+2
| | | | | | | | In commit 4620cf77f2 (Clang: Remove unused CUDA implicit link variables, 2021-02-14) we removed some references. It turns out they are non-empty and necessary if using a non-scattered installation. Fixes: #21863
* Clang: Remove unused CUDA implicit link variablesRaul Tambre2021-02-141-2/+2
| | | | We don't use/need implicit links for Clang with CUDA.
* Makefiles Generators: use compiler for dependencies generationMarc Chevrier2020-11-291-0/+6
| | | | | | | | | | | Each source compilation generates a dependencies file. These dependencies files are consolidated in one file per target. This consolidation is done as part of command 'cmake -E cmake_depends` launched before evaluation of makefile dependency graph. The consolidation uses the same approach as `CMake` dependencies management. Fixes: #21321
* Refactoring: Introduce place-holder for dependency target.Marc Chevrier2020-11-281-1/+1
| | | | | | | | These changes are in preparation of compiler generated dependencies support for Makefiles generators * compiler output and dependency target can be different for Makefiles generators * resolve inconsistency naming for dependency file place-holder
* CUDA: Clang separable compilationRaul Tambre2020-09-241-0/+1
| | | | | | | | | | | | For NVCC the compiler takes care of device linking when passed the "-dlink" flag. Clang doesn't support such magic and requires the buildsystem to do the work that NVCC does behind the scenes. The implementation is based on Bazel's device linking documentation: https://github.com/tensorflow/tensorflow/blob/7cabcdf073abad8c46e9dda62bb8fa4682d2061e/third_party/nccl/build_defs.bzl.tpl#L259 Closes: #20726
* CUDA: Fix Clang depfile flags when simulating MSVCRaul Tambre2020-06-081-0/+3
| | | | | | | | | __compiler_clang() doesn't call __compiler_gnu() if we're emulating MSVC. Thus CMAKE_DEPFILE_FLAGS_CUDA remains unset and compiling doesn't work, due to NVCC dependency injection workaround in CMakeCUDAInformation.cmake, which triggers for Ninja if they're not set. Always set the depfile flags to fix this. Most other compiler modules seem to do the same.
* CUDA: Add support for Clang compilerRaul Tambre2020-05-151-0/+25
When crosscompiling we pass the sysroot. We need to try various architecture flags. Clang doesn't automatically select one that works. First try the ones that are more likely to work for modern installations: * <=sm_50 is deprecated since CUDA 10.2, try sm_52 first for future compatibility. * <=sm_20 is removed since CUDA 9.0, try sm_30. Otherwise fallback to Clang's current default. Currently that's `sm_20`, the lowest it supports. Separable compilation isn't supported yet. Fixes: #16586