| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
| |
Clang 12 landed initial support for C++23 language mode flag -std={c|gnu}++2b
in commit 6627a3c2873fdf7ccba1a1573371079be48b36e8.
|
|
|
|
|
|
|
| |
We already detect `sizeof(void*)`. Detect the byte order as part of the
same check.
Issue: #21392
|
|
|
|
|
|
|
|
|
|
|
|
| |
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
|
|
|
|
|
| |
Similar to how we already do for Clang. Avoids a lot of redundant work in
FindCUDAToolkit.
|
|\ |
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Since commit 0d0145138f (CUDA: Add abstraction for cuda runtime
selection, 2019-11-29, v3.17.0-rc1~83^2) we add CUDA runtime library
selection flags by default.
To maintain backwards compatibility the default CUDA runtime
library needs to be computed based on what libraries are found
on the initial compiler invocation. For example a toolchain
could establish initial flags that have all CUDA compilations
using the runtime version, and if we don't detect this we will
try to link to both the static and shared runtime.
Co-Author: Brad King <brad.king@kitware.com>
Fixes: #20708
|
| | |
|
|/
|
|
|
|
| |
`link.exe /lib` is an undocumented flag and it just calls `lib.exe`.
Also `link.exe` doesn't parse the `/lib` option correctly when in a
response file.
|
|
|
|
|
|
|
| |
The CUDA language failed to persist CMAKE_SIZEOF_VOID_P
and CMAKE_INTERNAL_PLATFORM_ABI, causing find_ calls to fail when
the only enabled language was CUDA. This specifically occurred
when having to locate libraries inside `lib64` directories.
|
| |
|
|
|
|
|
|
| |
The CUDA language failed to persist CMAKE_CUDA_LIBRARY_ARCHITECTURE
and CMAKE_LIBRARY_ARCHITECTURE, causing find_ calls to fail when
the only enabled language was CUDA.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
- CMakeParseImplicitIncludeInfo.cmake: new parser that extracts the
compiler's include path from verbose output. If the parser cannot
parse the output, we fall back to the old behavior. On osx we skip
over framework directories (handled elsewhere).
- CMakeDetermineCompilerABI.cmake:
- use verbose flag in try_compile for ${src}
- use new cmake_parse_implicit_include_info() to attempt extract
implicit include directory path and if successful set
CMAKE_${LANG}_IMPLICIT_INCLUDE_DIRECTORIES
- CMakeCCompiler.cmake.in and CMakeCXXCompiler.cmake.in - preserve
CMAKE_${LANG}_IMPLICIT_INCLUDE_DIRECTORIES value between runs in
the same way CMAKE_${LANG}_IMPLICIT_LINK_DIRECTORIES is preserved
- Tests/RunCMake/ParseImplicitIncludeInfo: tests for parse
based on the older Tests/CMakeTests/ImplicitLinkInfoTest.cmake.in.
The test runs a set of verbose compiler outputs collected from
various machines through the parser and checks the results. New
compiler files can be added by dropping input/output files in the
ParseImplicitIncludeInfo/data subdirectory and then adding the new set
of files to the ${targets} list in ParseImplicitIncludeInfo.cmake.
There is a helper CMakeLists.txt in ParseImplicitIncludeInfo/data
that can help with the generation of test input files.
NOTE: the standard cmake pre-commit hook rejects verbose compiler
output with trailing spaces... you have to manually edit them out.
This shouldn't impact the test.
Note that both the parser and the test code can use CMAKE_${LANG}_COMPILER_*
variables such as ${CMAKE_CXX_COMPILER_ID} to decide how to parse
verbose compiler output. For the test code, this requires us to
save the variables values in the test input files.
Fixes: #16291
|
|
|
|
|
|
|
|
|
|
|
|
| |
CMake commands vs_link_dll and vs_link_exe, performing linking on MSVC,
are responsible for calling resource compiler and manifest tool.
Before this commit, both of these tools were called directly, with the
expectation that they are available in the `PATH`. This has been fixed
by respecting CMake variables `CMAKE_RC_COMPILER` and `CMAKE_MT`
defining paths to these tools.
Fixes: #17804
|
|
|
|
|
| |
We use this in `Modules/Platform/Windows-NVIDIA-CUDA.cmake`, so make
sure it is available.
|
|
|
|
| |
We already do this for C, CXX, Fortran, etc.
|
|
|
|
|
| |
The `nvcc -v` output provides what include directories need to be added
to use the CUDA toolkit from other languages ( C/C++ ).
|
| |
|
|
|
|
|
|
|
|
| |
Previously we had a two issues when building cuda executables
that required separable compilation. The first was that we didn't
propagate FLAGS causing any -arch / -gencode flags to be dropped, and
secondly generators such as ninja would use the CXX language flags
instead of CUDA when the executable was mixed language.
|
| |
|
|
|
|
| |
Report it in `CMAKE_CUDA_SIMULATE_{ID,VERSION}`.
|
| |
|
| |
|
| |
|
| |
|
|
|