spy icon indicating copy to clipboard operation
spy copied to clipboard

Detect CUDA and nvcc compiler

Open lahwaacz opened this issue 1 year ago • 2 comments

Can you add information for the detection of Nvidia's CUDA compiler (nvcc)? See https://docs.nvidia.com/cuda/cuda-compiler-driver-nvcc/index.html#nvcc-identification-macro

It would be nice to also be able to detect the CUDA compilation phases (host and device code generation). A caveat is that clang can also compile CUDA and uses different macros, see https://www.llvm.org/docs/CompileCudaWithLLVM.html#detecting-clang-vs-nvcc-from-code

lahwaacz avatar May 05 '23 11:05 lahwaacz