Suppress CUDA Warnings, master branch (2021.11.11.)
Disabled the "declared but never used" warning for the clients of AthCUDAKernelLib
. CUDA 11.4 is mistakenly issuing this warning for the variadic template code of the package. Which I was only able to disable in this global way.
I tried to make the following type of code work for a while:
#pragma diag_suppress = 177
...
// problematic code
...
#pragma diag_default = 177;
I tried with explicit codes, with declared_but_not_referenced
, and I also tried with nv_diag_suppress
instead of diag_suppress
. But the compilation didn't react to any of those.
For future reference: The way that I found the 177
code for this warning was by first adding the following for the build:
target_compile_options( AthCUDAKernelLib PUBLIC
$<$<COMPILE_LANGUAGE:CUDA>:-Xcudafe --display_error_number> )
This is all meant to address the warnings described in ATLINFR-4322.
While at it, I also set CMAKE_CUDA_ARCHITECTURES to compute capability 5.2 by default. This gets rid of the following warnings from our current build:
nvcc warning : The 'compute_35', 'compute_37', 'compute_50', 'sm_35', 'sm_37' and 'sm_50' architectures are deprecated, and may be removed in a future release (Use -Wno-deprecated-gpu-targets to suppress warning).
Which our current log parsing is blind to btw. @aundrus, could you add this pattern (nvcc warning :
) as a warning to the NICOS pages?