summaryrefslogtreecommitdiffstats
path: root/Modules/Compiler
Commit message (Collapse)AuthorAgeFilesLines
* IBMClang: No thin LTO on AIXNicole Rabjohn2023-03-231-1/+4
| | | | AIX does not yet support thin LTO.
* Merge topic 'clang-windows-cxx-modules'Brad King2023-03-211-13/+15
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | 1b7c26da49 Ninja: Wrap rules using '>' shell redirection with 'cmd /C' on Windows ffd8537acf Clang: Record Clang 16.0 C++ modules flags only for GNU-like front-end 6013227230 cmGlobalNinjaGenerator: Use forward slashes in clang modmap format on Windows d9d74b5e8a cmDyndepCollation: Drop outdated mentions of CXX_MODULE_INTERNAL_PARTITIONS edab56d29a cmLocalNinjaGenerator: De-duplicate condition for using 'cmd /C' on Windows 8ebe3f92b3 cmGlobalNinjaGenerator: Detect GNU-like command-line for dyndep collator f3ca199c9b cmGlobalNinjaGenerator: Factor out GNU-like command-line detection on Windows f79817fcf0 cmCxxModuleMapper: Use value semantics in path conversion callback ... Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !8346
| * Clang: Record Clang 16.0 C++ modules flags only for GNU-like front-endBrad King2023-03-201-13/+15
| | | | | | | | | | | | | | | | | | | | | | The settings added by commit 3fe8e33f27 (Clang: Record Clang 16.0 flags for our experimental C++ modules support, 2023-03-03, v3.26.0-rc6~6^2) work only for the GNU-like `clang++` front-end, and not for the MSVC-like `clang-cl` on Windows. Also quote the path to `clang-scan-deps` to support spaces in its path. Issue: #24611
* | IAR: Version update for arm assemblerJoakim Lönnberg2023-03-161-1/+1
| |
* | Merge topic 'iar-improve-asm'Brad King2023-03-152-27/+63
|\ \ | | | | | | | | | | | | | | | | | | 21f19d6af7 IAR:Improved assembler support Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !8323
| * | IAR:Improved assembler supportJoakim Lönnberg2023-03-142-27/+63
| | |
* | | Merge topic 'support_cubin_fatbin_optix_cuda_output'Brad King2023-03-141-0/+5
|\ \ \ | |/ / |/| | | | | | | | | | | | | | | | | 2def6a874b CUDA: Add support for CUBIN, FATBIN, and OPTIXIR compilation Acked-by: Kitware Robot <kwrobot@kitware.com> Acked-by: buildbot <buildbot@kitware.com> Merge-request: !8259
| * | CUDA: Add support for CUBIN, FATBIN, and OPTIXIR compilationRobert Maynard2023-03-131-0/+5
| | |
* | | Merge topic 'clang-16-cxx-modules'Brad King2023-03-061-0/+14
|\ \ \ | |/ / |/| / | |/ | | | | | | | | | | 3fe8e33f27 Clang: Record Clang 16.0 flags for our experimental C++ modules support Acked-by: Kitware Robot <kwrobot@kitware.com> Acked-by: scivision <michael@scivision.dev> Acked-by: Alex <leha-bot@yandex.ru> Merge-request: !8285
| * Clang: Record Clang 16.0 flags for our experimental C++ modules supportBrad King2023-03-031-0/+14
| | | | | | | | LLVM/Clang 16.0 now contains official support for what CMake needs.
* | IAR: Tolerate variables named for languagesJoakim Lönnberg2023-02-211-1/+1
| | | | | | | | | | | | | | | | | | | | | | If a project or user sets a variable or cache entry named `C` or `CXX`, we were previously comparing those language names to the value of that variable, rather than the name itself. Double-quote the string to take advantage of policy `CMP0054`, but also add "x" prefixes to support projects that do not set the policy. This extends a similar fix from commit c8eb357738 (CompilerId: Tolerate variables named for languages, 2021-06-17, v3.21.0-rc1~9^2).
* | LCC: Disable Fortran preprocessor testing if unsupportedmakise-homura2023-02-161-2/+5
|/ | | | | | LCC < 1.24 has no way to disable integrated Fortran preprocessor, and it can't produce preprocessed files explicitly. So we disable all functionality (and therefore tests) related to it.
* LLVMFlang: Fix post-preprocess compile for fixed-form FortranDavid Truby2023-02-141-0/+1
| | | | | | | | | | | | LLVM Flang's preprocessor output is always valid fixed form Fortran with a fixed line length of 72. If an application tries to use fixed form with a different line length, this will fail in the post-preprocessing compilation step as they will pass a flag asking for a different fixed line length. To fix this we can pass -ffixed-line-length-72 to the post-preprocess compilation stage. This will be ignored when the input is free form Fortran, and force to a 72 line length when the input is fixed.
* LCC: Fix extraction of __LCC__ version componentsBrad King2023-02-132-8/+4
| | | | | Previously the logic only worked for major versions of the form `1.xx`. Fix it to work with versions `2.xx` and above.
* Merge topic 'android-ndk-legacy-toolchain' into release-3.26Brad King2023-02-071-1/+1
|\ | | | | | | | | | | | | cb0b9452e8 Android: Provide CMAKE_ANDROID_NDK_VERSION with NDK legacy toolchain file Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !8170
| * Android: Provide CMAKE_ANDROID_NDK_VERSION with NDK legacy toolchain fileBrad King2023-02-061-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This variable has been provided since commit 746906242d (Android: Detect NDK version number, 2021-02-26, v3.20.0-rc3~1^2~3) when using CMake's NDK support or the modern NDK toolchain file. Since commit 005e2cdfb0 (Android: Do not use gold for ndk >= r22, 2021-02-26, v3.20.0-rc3~1^2) we need the value in our compiler/platform information files, so provide it when using the NDK legacy toolchain file too. Revert commit 1c86e397fe (Android/Clang: Tolerate undefined CMAKE_ANDROID_NDK_VERSION, 2022-09-16, v3.25.0-rc1~118^2) since the variable should now always be defined. Issue: #21772 Fixes: #24386
* | Modules: Record system inspection steps in the configure logBrad King2023-01-181-2/+2
| | | | | | | | | | | | | | | | Replace old-style `file(APPEND .../CMake{Output,Error}.log)` logging with calls to `message(CONFIGURE_LOG)` to record the steps in the `CMakeConfigureLog.yaml` configure log instead. Issue: #23200
* | IntelLLVM: Add provisional flags for C23 and C++23scivision2023-01-162-0/+12
| |
* | IntelLLVM: Replace -Qstd= with -Qstd: on Windowsscivision2023-01-161-6/+6
| | | | | | | | | | | | The latter is the documented form [1]. [1] https://www.intel.com/content/www/us/en/develop/documentation/oneapi-dpcpp-cpp-compiler-dev-guide-and-reference/top/compiler-reference/compiler-options/language-options/std-qstd.html
* | Merge topic 'IntelLLVM-msvc-no-cxx11'Brad King2023-01-131-2/+2
|\ \ | |/ | | | | | | | | | | 88f9fdcb03 IntelLLVM: Avoid unnecessary -Qstd=c++11 flag on Windows Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !8069
| * IntelLLVM: Avoid unnecessary -Qstd=c++11 flag on WindowsBrad King2023-01-121-2/+2
| | | | | | | | | | | | | | | | The IntelLLVM compiler, for compatibility with MSVC on Windows, always runs with support for at least C++14. The `-Qstd=c++11` flag just causes a warning that it is unused. Fixes: #24316
* | Merge topic 'cuda-nvcc-cuda20'Brad King2022-12-141-0/+12
|\ \ | |/ | | | | | | | | | | 0aeeb8160c CUDA: Add support for cuda_std_20 for nvcc 12.0+ Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !8008
| * CUDA: Add support for cuda_std_20 for nvcc 12.0+Robert Maynard2022-12-131-0/+12
| | | | | | | | CUDA 12.0 has been released with support for `-std=c++20`.
* | Clang-FindBinUtils: also find `clang-scan-deps`Ben Boeckel2022-12-021-0/+11
| | | | | | | | `clang-scan-deps` will be required for C++20 module scanning purposes.
* | Merge topic 'iar-rsp-on-objects'Brad King2022-11-291-22/+16
|\ \ | | | | | | | | | | | | | | | | | | a51e01f2ec IAR: Add response flag for files Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !7957
| * | IAR: Add response flag for filesFelipe Torrezan2022-11-271-22/+16
| | |
* | | Merge topic 'msvc-cxx-no-optin-experimental-flag'Brad King2022-11-291-1/+0
|\ \ \ | |/ / |/| / | |/ | | | | | | | | 12e4bc73cb MSVC: don't opt into dyndep support Acked-by: Kitware Robot <kwrobot@kitware.com> Acked-by: buildbot <buildbot@kitware.com> Merge-request: !7965
| * MSVC: don't opt into dyndep supportBen Boeckel2022-11-281-1/+0
| | | | | | | | | | | | | | Instead, just set the variables for how scanning works since that is part of the compiler mechanisms. Fixes: #24198
* | Only initialize CMAKE_CXX_COMPILER_PREDEFINES_COMMANDJoerg Bornemann2022-11-168-42/+56
| | | | | | | | | | | | | | | | | | | | | | Don't initialize the other CMAKE_<LANG>_COMPILER_PREDEFINES_COMMAND variables. The only language variant that is used is CMAKE_CXX_COMPILER_PREDEFINES_COMMAND, and the other language variants contained invalid, namely C++-specific commands. Fixes: #23968
* | Merge topic 'nvcc-isystem'Brad King2022-11-141-1/+1
|\ \ | |/ |/| | | | | | | | | 207fd956d8 CUDA: Use consistent -isystem flag style for NVIDIA nvcc Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !7904
| * CUDA: Use consistent -isystem flag style for NVIDIA nvccYantaoZhao2022-11-111-1/+1
| | | | | | | | | | | | Replace `-isystem=` with `-isystem ` for consistency with other compilers. Fixes: #24154
* | msvc: bless MSVC 19.34 support for C++ modules as experimentalBen Boeckel2022-11-111-0/+12
|/ | | | Visual Studio 17.4 now contains official support for what CMake needs.
* Tasking: Remove CMAKE_SYSTEM_PROCESSOR support per CMP0123Christoph Seitz2022-11-071-32/+0
| | | | | | | Architecture specific compile options should be set through toolchain files. Fixes: #24115
* Tasking: Fix PIC option for Tasking ToolsetGordon Jess2022-11-031-1/+1
| | | | Fixes: #24114
* IAR: Restore support for CMAKE_CXX_FLAGS_INITDaniel Schürmann2022-11-011-2/+2
| | | | | | | | | | | | Prior to commit a9073db736 (IAR: update language specification detection, 2021-09-23, v3.22.0-rc1~83^2) the `--c++`/`--eec++` flags were stored in `CMAKE_IAR_CXX_FLAG` so that they would be used as part of the `CMAKE_CXX_COMPILE_OBJECT` rule variable. That commit moved the flags to `CMAKE_CXX_FLAGS`, which also broke initialization of `CMAKE_CXX_FLAGS` from `CMAKE_CXX_FLAGS_INIT`. Restore the original approach. Fixes: #24111
* Merge topic 'flang-implicit-link-info' into release-3.25Brad King2022-10-121-0/+2
|\ | | | | | | | | | | | | | | 0301779e85 LLVMFlang: Add support for mixed-language linking with Fortran Acked-by: Kitware Robot <kwrobot@kitware.com> Acked-by: buildbot <buildbot@kitware.com> Merge-request: !7781
| * LLVMFlang: Add support for mixed-language linking with FortranBrad King2022-10-111-0/+2
| | | | | | | | | | | | | | | | | | Parse implicit link information for this compiler to support mixed-language linking. This was missed by commit 85749766df (LLVMFlang: Add support for LLVM Flang, 2021-07-07, v3.24.0-rc1~86^2). Also activate mixed-language test cases that would have caught this. Issue: #22387
* | Merge topic 'Intel-Fortran-warn-errors'Brad King2022-10-104-8/+22
|\ \ | |/ | | | | | | | | | | | | | | 13f3382b1c Intel/IntelLLVM: Fortran has distinct "-Werror"-like flag ab8a0a106e COMPILE_WARNING_AS_ERROR: Fix internal formatting of options table Acked-by: Kitware Robot <kwrobot@kitware.com> Acked-by: buildbot <buildbot@kitware.com> Merge-request: !7758
| * Intel/IntelLLVM: Fortran has distinct "-Werror"-like flagMichael Hirsch2022-10-072-6/+20
| | | | | | | | | | | | | | Update the compiler options table added by commit 76a08cd253 (COMPILE_WARNING_AS_ERROR: Add options to treat warnings as errors, 2022-04-21, v3.24.0-rc1~173^2) to use the Intel Fortran compilers' dedicated `-warn*` flags.
| * COMPILE_WARNING_AS_ERROR: Fix internal formatting of options tableBrad King2022-10-072-2/+2
| | | | | | | | | | | | | | | | In commit 76a08cd253 (COMPILE_WARNING_AS_ERROR: Add options to treat warnings as errors, 2022-04-21, v3.24.0-rc1~173^2) we formatted the options table entries as command-line string fragments. Since they are part of the `CMAKE_${lang}_COMPILE_OPTIONS_*` tables, they should be formatted as `;`-separated lists of compiler options.
| * Merge topic 'warning-as-error-ti-compiler' into release-3.24Brad King2022-08-151-0/+1
| |\ | | | | | | | | | | | | | | | | | | | | | 1cd65dfa0e TI compiler: Add support for COMPILE_WARNING_AS_ERROR target property Acked-by: Kitware Robot <kwrobot@kitware.com> Acked-by: Josef Angstenberger <code@jtxa.de> Merge-request: !7560
* | | Tasking: Simplify processor list matching regexHutchings Samuel (ETAS/ERS-PRM)2022-10-071-2/+2
| | |
* | | Android/Clang: Tolerate undefined CMAKE_ANDROID_NDK_VERSIONBoris Egorov2022-09-161-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The previous fix for #21772, commit 005e2cdfb0 (Android: Do not use gold for ndk >= r22, 2021-02-26, v3.20.0-rc3~1^2), doesn't work with typical android toolchain file, like this one: https://android.googlesource.com/platform/ndk/+/master/build/cmake/android-legacy.toolchain.cmake The condition fails to work when CMAKE_ANDROID_NDK_VERSION is undefined: second part evaluates to true, although ndk version is not known. I've encountered following environment where CMAKE_ANDROID_NDK_VERSION is used without definition: * Build uses android toolchain file, which sets CMAKE_SYSTEM_VERSION=1 and doesn't set CMAKE_ANDROID_NDK_VERSION. * Code in Platform/Android-Determine.cmake exits early when it detects toolchain usage (via value CMAKE_SYSTEM_VERSION=1). This file is the only place in cmake modules where variable CMAKE_ANDROID_NDK_VERSION is set, and by early return we skip this definition.
* | | Tasking: Add support for several compiler toolsetsChristoph Seitz2022-09-146-0/+199
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add support for the Tasking compiler toolset: * TriCore Compiler Toolset 6.3 (with TriCore, ARM, MCS, 8051 and PCP architecture compilers) * SmartCode Compiler Toolset 10.1 (with TriCore, ARC, MCS, 8051 architecture compilers) * ARM Compiler 6.0 * MCS Complier 3.3 * 8051 Compiler 7.2 Fixes: #23756
* | | CMake: Support upcoming C++26 language levelRobert Maynard2022-08-312-0/+2
| | |
* | | Merge topic 'warning-as-error-ti-compiler'Brad King2022-08-151-0/+1
|\ \ \ | | |/ | |/| | | | | | | | | | | | | | | | 1cd65dfa0e TI compiler: Add support for COMPILE_WARNING_AS_ERROR target property Acked-by: Kitware Robot <kwrobot@kitware.com> Acked-by: Josef Angstenberger <code@jtxa.de> Merge-request: !7560
| * | TI compiler: Add support for COMPILE_WARNING_AS_ERROR target propertyCraig Scott2022-08-111-0/+1
| | |
* | | Merge topic 'mingw-flto'Brad King2022-08-151-1/+8
|\ \ \ | | |/ | |/| | | | | | | | | | | | | 7b2a87c2eb IPO: Do not use -flto=auto with GCC 10.x on Windows Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !7559
| * | IPO: Do not use -flto=auto with GCC 10.x on WindowsBrad King2022-08-101-1/+8
| |/ | | | | | | | | | | | | | | | | Revise the change from commit fe57410b33 (IPO: Use -flto=auto if compiler is GCC >= 10.1, 2022-06-22, v3.24.0-rc2~2^2) to require at least GCC 11 on Windows. Fixes: #23836 Issue: #23640
* | Merge topic 'enable-intel-llvm-ipo-3'Brad King2022-08-042-6/+60
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | c633bd76d8 Add linker prefix for "-stack" flag on MSVC builds 6823db0c5a Enable IPO for IntelLLVM compilers on Linux and Windows adbffd204d Propagate OpenMP compiler flags to linker for IntelLLVM 3640842df2 Tests: Update ModuleDefinition for IntelLLVM MSVC Frontend Variant 5d5a712303 IntelLLVM: Pass linker flags to the compiler when used as linker Acked-by: Kitware Robot <kwrobot@kitware.com> Acked-by: buildbot <buildbot@kitware.com> Merge-request: !7533