Incorrectly getting "Enabling single compilation unit for the CUDA non-bonded module." when using Cuda 9.0 and gromacs 2018.1 - Redmine #2561
The Cmake code in cmake/gmxManageGPU.cmake incorrectly ends up in the
message(STATUS “Enabling single compilation unit for the CUDA non-bonded module….”
part of the if-stmt when building with CUDA 9.9
It does this despite correctly identifying CUDA 9.0 and using only >= 3.0 cuda targets.
Since the code in cmake/gmxManageNvccConfig.cmake correctly sets GMX_CUDA_NVCC_FLAGS regardless of doing autodetection or using user specified SM/COMPUTE targets, the code in cmake/gmxManageGPU.cmake macro(gmx_gpu_setup) can be simplified to:
if (GMX_GPU AND NOT GMX_CLANG_CUDA) gmx_check_if_changed(_gmx_cuda_target_changed GMX_CUDA_NVCC_FLAGS) if(_gmx_cuda_target_changed OR NOT GMX_GPU_DETECTION_DONE) if(GMX_CUDA_NVCC_FLAGS MATCHES "_2") message(STATUS "Enabling single compilation unit... else() message(STATUS "Enabling multiple compilation ...
(This is the problem I incorrectly targeted in issue 2560)
(from redmine: issue id 2561, created on 2018-06-26 by akesandgren, closed on 2018-08-21)
- relates #2390 (closed)
- Revision 1982bad5 by Szilárd Páll on 2018-08-20T23:18:42Z:
Disable single compilation unit with CUDA 9.0 CUDA 9.0 does not support CC 2.x, hence even with the default list of targeted arch, multiple compilation units an be enabled. Fixes #2561 Change-Id: I741081da39539f211fad32bda5c1f1dccc4378f9