Default host compiler used by nvcc for linux

流过昼夜 提交于 2019-11-30 07:55:14

You want the -ccbin option for nvcc, e.g. to use icpc (the Intel C++ compiler), use nvcc -ccbin=icpc (assuming the icpc is available in your $PATH).

Note that you should always pass a C++ compiler (g++, icpc, etc.), since nvcc treats the code as C++, even when it's C code.

AFAIK it uses g++ (to be more precise it uses gcc with language set to c++) and of course g++ for final linking. Run nvcc with --verbose option to see more detail if you want.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!