cancel
Showing results for 
Search instead for 
Did you mean: 

Archives Discussions

jason
Adept III

AMD OpenCL 2.0 with C++ static kernel extension?

Hi!

I very much like that AMD has the C++ static kernel extension - this lets us use things like type traits and template specialization, which are major features of CUDA and lets us keep things flexible and fast and often more concise.

I like that there is an SDK support OpenCL 2.0 now too.  But when I take my build flags and change the cl-std to 2.0, I find I get an error with the -x clc++ argument:

error: unknown argument: '--c++'

And the compiler proceeds to spazz out on my templates.

Any idea what's going on AMD devs?

0 Likes
4 Replies
ginquo
Adept II

One thing you could look into, would be using Clang to compile C++ code to SPIR and using that. That would also have the advantage that it would work with non-AMD implementations of OpenCL.

0 Likes
dipak
Big Boss

Currently static c++ kernel is not supported for compiling code as OpenCL 2.0. As a result, you're getting compilation error when use "-x clc++" option with "-cl-std=CL2.0".

Regards,

0 Likes
jason
Adept III

I see - any idea when it's going to be supported?

0 Likes

Right now, I don't know about the time-line. If I get any information about that, I'll share with you.

0 Likes