gcc 4.7 version issue about CUDA 5.0

What version does CUDA 5.0 support? Currently we are using gcc 4.4.7, only to be compatible with CUDA 5.0. I wonder if gcc 4.7 is possible for compiling CUDA 5.0? If not, does NVIDIA have plan to support 4.7(even 4.8)?

Thanks!

Isn’t CUDA compiled with NVCC not GCC? The device code at least…

Or do You ask for the support of C++11 in NVCC?

I think it supports gcc 4.6 officially. But you can make gcc 4.7 work too.

Create a header file “gcc_cuda_compat.h” and put the following inside:

#undef _GLIBCXX_ATOMIC_BUILTINS
#undef _GLIBCXX_USE_INT128

Add the following flag to nvcc when you compile: “–pre-include /path/to/your/file/gcc_cuda_compat.h”.

Found the answer a while back here: FS#29359 : [cuda-toolkit] Incompatibility with GCC 4.7. Worked for me.