3 ms·
nvcc is nowhere near that bad these days, it supports most C++ code directly (for example, I've written kernels that include headers like <span> or <algorithm>
by saagarjha 2y ago
nvcc is nowhere near that bad these days, it supports most C++ code directly (for example, I've written kernels that include headers like <span> or <algorithm> and they work just fine).
- ckitching 2y agoNVCC is doing much better than before in terms of "broken C++". There was indeed a time when lots of modern C++ just didn't work. Nowadays the issues are more subtle and nasty. Subtle differences in overload resolution. Subtle differences in lambda handling. Enough to break code in "spicy" ways when you try to port it over.
- saagarjha 2y agoWhat do you think the source of this is? My understanding was that Nvidia is basically adopting the clang frontend wholesale now so I'm curious where it differs.
- ckitching 2y agoThe LLVM manual touches on some of the basics of why: https://llvm.org/docs/CompileCudaWithLLVM.html#dialect-differences-between-clang-and-nvcc https://llvm.org/docs/CompileCudaWithLLVM.html#dialect-diffe...