Default host compiler used by nvcc for linux

后端 未结 2 640
走了就别回头了
走了就别回头了 2020-12-30 17:34

I am using CUDA 4.0 on Ubuntu 10.10 with GTX 570 (compute capcability 2.0), with the GCC compiler suite. As I understand it, during compilation the CUDA compiler driver nvc

相关标签:
2条回答
  • 2020-12-30 18:02

    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.

    0 讨论(0)
  • 2020-12-30 18:11

    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.

    0 讨论(0)
提交回复
热议问题