| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
We run a `try_compile` with a tiny test source to check if the compiler
works so that we can fail early if it does not. When the compiler does
work, we immediately `try_compile` the ABI detection source. In the
common case that both steps work, we gain no useful information from the
first one and the work was wasted.
Re-order the checks to try the ABI detection first. If it works then
assume the compiler works and skip the dedicated check. If the ABI
check fails then proceed with the normal test for a working compiler so
the diagnostic can be shown as before.
Fixes: #18703
|
|
|
|
|
|
| |
Filter CMAKE_CUDA_HOST_IMPLICIT_LINK_LIBRARIES just after it is
computed. Re-use the same exclusion list for filtering
CMAKE_CUDA_IMPLICIT_LINK_LIBRARIES to avoid duplication.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
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
|
|
|
|
|
|
|
|
|
|
| |
The special case added by commit 87df637078 (CUDA: Do not treat CUDA
toolkit include directories as implicit, 2020-02-02, v3.17.0-rc1~31^2)
breaks CMake's protections against changing the compiler's implicit
include directory order. Do this only for the NVIDIA compiler where it
is needed as a workaround to another problem. That compiler does not
put the host compiler's implicit include directories in `-I` paths so we
do not detect them as `CMAKE_CUDA_TOOLKIT_INCLUDE_DIRECTORIES` anyway.
|
|
|
|
|
|
|
|
|
| |
CMake properly detects the toolkit directories as implicit system
includes, but CUDA compilers don't add explicit `-isystem` markups to
these directories when compiling CUDA code. Due to this limitation,
allow users to explicitly specify these directories as SYSTEM dirs.
Fixes: #16464, #19864
|
|
|
|
|
| |
Fixes #17559
Replace our hard-coded default of cudart=static with a first-class abstraction to select the runtime library from an enumeration of logical names.
|
| |
|
|
|
|
| |
Co-Authored-By: Craig Scott <craig.scott@crascit.com>
|
|
|
|
| |
Found via `codespell`
|
|
|
|
|
|
| |
When we report that a compiler was unable to build a simple test
program, indent the output of the attempt so that our message formatting
will show it as a pre-formatted block.
|
|
|
|
|
| |
The `nvcc -v` output on Windows uses response files, so load the one we
need to extract the full link line.
|
| |
|
|
|