You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Mar 20, 2023. It is now read-only.
Repository navigation
This repository was archived by the owner on Mar 20, 2023. It is now read-only.
Describe the solution you'd like
We should avoid deprecated features and follow upstream recommendations, i.e. stop using FindCUDA, cuda_add_library etc.
Additional context
I suspect that the legacy code does not correctly declare all build dependencies, and that it is responsibly for cmake --build re-running the CMake configuration more often than necessary.
In #609 I moved to using CMake's CUDA language support, initially using CMake v3.20. I then added workarounds for older versions back to v3.15.
An attempted GPU build with CMake v3.10 / CUDA 11.0 / NVHPC 21.7 did not go so well. CMake labels the NVHPC C/C++ compilers as PGI 21.7, but it does not know how to detect the language features that they support. And it does not seem to be possible to distinguish programmatically between the two cases:
C++ feature X is known to be unsupported by PGI/NVHPC version Y
No test is implemented for C++ feature X for PGI/NVHPC compilers
The result is that the check introduced in #591 fails. If this test is disabled for PGI/NVHPC, we hit a similar issue with the catch2 submodule of NEURON. If we add workarounds for both of these (I just skipped the check for CoreNEURON and manually kludged CMAKE_CXX_COMPILE_FEATURES for catch2, but it's not important) then there is a further issue:
The CUDA_RESOLVE_DEVICE_SYMBOLS target property is now supported on shared library, module library, and executable targets. Previously it was only honored on static libraries.
from the v3.14 release notes, but the changes of #609 rely on setting this property on executable targets. This looks more awkward to work around.
Activity
olupton commentedon Apr 20, 2021
See also: https://cliutils.gitlab.io/modern-cmake/chapters/packages/CUDA.html
alkino commentedon May 15, 2021
We have to support both for a long time, minimum version of cmake for CoreNeuron is 3.7.
pramodk commentedon May 15, 2021
@alkino : With 8.0 release done, we can bump the minimum requirement to from 3.7 to something more "reasonable".
olupton commentedon Aug 13, 2021
In #609 I moved to using CMake's CUDA language support, initially using CMake v3.20. I then added workarounds for older versions back to v3.15.
An attempted GPU build with CMake v3.10 / CUDA 11.0 / NVHPC 21.7 did not go so well. CMake labels the NVHPC C/C++ compilers as PGI 21.7, but it does not know how to detect the language features that they support. And it does not seem to be possible to distinguish programmatically between the two cases:
Xis known to be unsupported by PGI/NVHPC versionYXfor PGI/NVHPC compilersThe result is that the check introduced in #591 fails. If this test is disabled for PGI/NVHPC, we hit a similar issue with the
catch2submodule of NEURON. If we add workarounds for both of these (I just skipped the check for CoreNEURON and manually kludgedCMAKE_CXX_COMPILE_FEATURESforcatch2, but it's not important) then there is a further issue:which is presumably because of
from the v3.14 release notes, but the changes of #609 rely on setting this property on executable targets. This looks more awkward to work around.