Nvfortran: reducing optimation level by multiple -On does not work

In a project I am trying to work around an ICE that appears at -O2 but not at -O1 or -O0. But using a common set of flags in the Makefile and reducing optimization for a single file is unnecessarily cumbersome:

% nvfortran -V -O2 -O1
nvfortran-Info-Switch -Mvect forces -O2

nvfortran 21.9-0 64-bit target on x86-64 Linux -tp haswell 

It would be great if this could be made to work the same as for other compilers.

Thanks,
Harald

Hi Harold,

I added a problem report, TPR #30743, and sent it to engineering for investigation.

-Mat