This compiles without errors but clearly doesn’t work. I still get optimized code!
/usr/local/cuda/bin/nvcc -gencode=arch=compute_20,code="sm_20,compute_20" -m32 -O0 --ptxas-options -O0 --compiler-options -fno-strict-aliasing -I. -I/usr/local/cuda/include -I…/…/common/inc -I…/…/…/shared//inc -DUNIX -o vectorAdd.cuo -c vectorAdd.cu
I believe Nvidia made the compiler execute many optimization passes unconditionally since e.g. compute capability 1.x devices have to use inlining to make functions work at all.
Oops, yes. You need to pass [font=“Courier New”]–opencc-options=-O0[/font] to nvcc. Somehow I missed you were doing that for ptxas and for the host compiler, but not for nvopencc.