PDA

View Full Version : OpenCL 1.2 Class Inheritance



Bacterius
10-01-2012, 03:09 AM
Hello,
I have been looking at the new C++ static kernel language available in OpenCL 1.2 (or at least, AMD's version of it) and am wondering if anyone has had previous experience with it, particularly when it comes to class inheritance?

I would like to be able to pass an array of classes to my kernel, all the classes are derived from a same base class and may have different, but relatively simple fields, and different implementations of course, but I fail to see how this can be possible with current GPU technology without a very heavy use of reflection.

Or are classes only available for use *within* the kernel and cannot be used as parameters? It's not clear from the reference document and the only sample using such kernels only uses the new templates and ignores classes completely.

Thanks.

Bacterius
10-07-2012, 12:53 PM
l3ump!