[codebox]constant char data[10] = {1,-1,2,1,1,1,1,-2,1,2};
kernel void foo(){
...
}
[/codebox]
I wish to make use of the 64k constant memory by replacing a small Global with a small array like above, except length 2500.
The above example works, and I should mention that I build / assemble my OpenCL on the fly, so doing this is no problem. Would doing this affect compile time very badly? If multiple kernels needed the same array is in-lining the wrong way to go? Is there even another way? All I see are ways to load & pass as parameters Globals & Images (plus initial Locals).