CUDA 4.0 RC2 + VS 2010 omits /Wn compile flag C Warning level flag is being ignored

Hi,

If I build a project, even one from the SDK, then no C warnings are generated at compile time, even if the warning level is set.

For instance, using the clock SDK example. No changes to the properties. Here is the command line with arguments (from Properties → CUDA C/C++ → Command Line

Driver API (NVCC Compilation Type is .cubin, .gpu, or .ptx)

set CUDAFE_FLAGS=–sdk_dir “C:\Program Files (x86)\Microsoft SDKs\Windows\v7.0A"
“C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v4.0\bin\nvcc.exe” --use-local-env --cl-version 2010 -ccbin “C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\bin” -I”./" -I"…/…/common/inc" -I"…/…/…/shared/inc" -G0 --keep-dir “Debug” -maxrregcount=32 --machine 32 --compile -o “Win32/Debug/%(Filename)%(Extension).obj” “%(FullPath)”

Runtime API (NVCC Compilation Type is hybrid object or .c file)

set CUDAFE_FLAGS=–sdk_dir “C:\Program Files (x86)\Microsoft SDKs\Windows\v7.0A"
“C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v4.0\bin\nvcc.exe” --use-local-env --cl-version 2010 -ccbin “C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\bin” -I”./" -I"…/…/common/inc" -I"…/…/…/shared/inc" -G0 --keep-dir “Debug” -maxrregcount=32 --machine 32 --compile -D_NEXUS_DEBUG -g -Xcompiler "/EHsc /nologo /Od /Zi /MDd " -o “Win32/Debug/%(Filename)%(Extension).obj” “%(FullPath)”

You can see that the /W3 option is missing.

If I change other flags, such as the Optimization level, it updates the nvcc.exe command line arguments.