cancel
Showing results for 
Search instead for 
Did you mean: 

Archives Discussions

gtanski
Journeyman III

OpenCL clc.exe bug

pointer-to-function call crashes clc.exe

This simple code causes a crash in clc.exe while trying to compile it.

This is actually calling function at 0 and should cause crash at runtime, but its just simplest example. Any pointer-to-function call I've tried cannot be compiled due crash of clc.

 

 

__kernel void dot_product(__global const float4 *a,__global const float4 *b, __global float *c){ void (*temp)()=(void(*)())0; temp(); // crash of CLC }

0 Likes
1 Reply
omkaranathan
Adept I

As per OpenCL specification, pointers to functions are not allowed inside the kernel.

0 Likes