Appendix D of the 3.2 version of the CUDA documentation refers to C++ support in CUDA device code.
It is clearly mentioned that CUDA supports \"Classes for devices of co
Oficially, CUDA has no support for classes on devices prior to 2.0.
Practically, from my experience, you can use all C++ features on all devices as long as the functionality can be resolved at compile-time. Devices prior to 2.0 do not support function calls (all functions are inlined) and no program jumps to a variable address (only jumps at constant address).
This means, you can use the following C++ constructs:
You cannot use the following:
Actually, all examples in chapter D.6 of the CUDA Programming Guide can compile for devices <2.0
Some C++ class functionality will work, however the Programming Guide is basically saying that it's not fully supported and therefore not all C++ class functionality will work. If you can do what you're looking to do then you should go ahead!