nvcc problem --cubin with --arch=compute_11

Hi, i want to compile a .cu file to cubin (i use CUDA.NET, which only loads cubin files), and i want to use some atomic functions. In order to use atomic functions you must specify the architecture (–arch=compute_11). And there comes the problem, if you compile the files with --cubin and --arch=compute_11, you will get the error:
nvcc Option ‘-cubin’ is not allowed when compiling for a virtual compute architecture
Is there any workaround for this?

Try -gencode arch=compute_11,code=sm_11 instead of the arch option you are using.

it’s working! thanks
nvcc cuda.cu --cubin -gencode arch=compute_11,code=sm_11 -w