The following code uses a struct, passed into the kernel, containing a global pointer. The pointer however is not used inside the kernel until initialized to point to the floats0 global float * array. Is there anything in the OpenCL 1.2 spec that says this is/isnt legal?
struct Eigen__TensorEvaluator {
global float* f0;
float f1;
};
kernel void foo(global struct Eigen__TensorEvaluator* pstruct, global float* floats0) {
pstruct[0].f0 = floats0;
pstruct[0].f0[0] = pstruct[0].f1;
}