How can I get the Apple OpenCL compiler to recompile the cached kernel?

I want to use the #include instructions in my OpenCL cores, but the Apple OpenCL kernel appears to cache the caches, so if you change the contents of the included file, but not the file making the inclusion, the program will not change between runs.

I coded an example that illustrates this: http://github.com/enjalot/adventures_in_opencl/tree/master/experiments/inc/

If you compile and run, it should work fine. Then, if you comment out the structure definition in inc.cl, it will still work just fine (or change something in lvl2.cl)

Using the NVIDIA compiler on Ubuntu, you get the expected behavior.

So, is there a way to get clBuildProgram to recompile the kernel?

+5
source share
1 answer

I got a response from the perfoptimization-dev@apple.com mailing list

sudo killall cvmsServ

Doesn't seem very elegant, but oh well

+3
source

All Articles