Silencing CUDA link warnings in an OpenACC project

Hello,

I am working with a large C++ / OpenACC project. In this project we utilize recursion in a few places, which results in errors like the following at link time:

nvlink warning : Stack size for entry function ‘_ZNK4nifr18ZXSPPLimiterScalarINS_17SolutionConvertorINS_24EOSFR_TabulatedChemistryEEEE4calcEv_348_gpu’ cannot be statically determined

We are aware of the root cause of this problem, and we intend to refactor the code completely in the future to make it more GPU friendly. For the time being we have simply blocked off GPU execution of the associated module. However, the warning messages are causing problems with our build system and I would like to silence this output. Is it possible to pass an argument to pgc++ to silence this output? If not, can it somehow be set through an rc file?

Thanks,

-David

minor correction: these are warnings, not errors.

Hi David,

I checking with the compiler team to see what can be done.

-Mat

Hi Mat,

Thanks for the quick response. I think we found a workaround with some template tricks to avoid the recursion, but I’m still curious to hear if there is a supported way to propagate this kind of control down to nvlink.

Thanks,

-David

Hi David,

While nvlink warnings can be disabled via the “-w” flag, we don’t have a method for you to pass the flag through. I filed an RFE (TPR #30838), to see if we can add something.

-Mat

Hi David,

In 21.11, we added a “-Wnvlink,” option which will pass flags to nvlink. Can you try using 21.11 with “-Wnvlink,-w” to see if it solves your issue?

-Mat