I’ve started to do some serious programming with OpenCL, and while it is a truly remarkable system for portable parallel programming, all things aren’t necessarily obvious. I’m even developing and writing code on AMD and NVIDIA systems (both under Windows for the time being), so I get to compare and contrast the differences. I’m going to try to keep a (living) list of some of the interesting things I find, that may not entirely be too obvious.
- The “#pragma” compiler directives have be included at the beginning of the very first string in the string array sent to clBuildProgram.
- On AMD systems, each “#pragma” directive has to be included in its own “\n” terminated string.
I’ll keep updating this list as I find the peculiarities.