4 questions
1
vote
1
answer
46
views
Why can't I create a kernel (CL_INVALID_PROGRAM_EXECUTABLE) after successfully compiling an OpenCL program?
In the following program, I compile a kernel for the first device on the first platform:
const char* kernel_source_code = R"(
__kernel void vectorAdd(
__global float * __restrict C,
...
1
vote
0
answers
50
views
Are OpenCL kernel NDarrays necessarily limited to 3 dimensions?
I'm looking at the OpenCL specification for clGetKernelWorkGroupInfo(), and am noticing that the returned types for CL_KERNEL_GLOBAL_WORK_SIZE and CL_KERNEL_COMPILE_WORK_GROUP_SIZE are both size_t[3]. ...
0
votes
0
answers
17
views
Why does OpenCL not have a clGetKernelArg function?
In OpenCL, before launching a kernel, we set its arguments using the clSetKernelArg() API function; and the cl_kernel handle must be backed by some kind of storage for the value of those arguments we ...
2
votes
1
answer
64
views
What happens to set kernel arguments after launch? Must I reset them?
In CUDA, launching a kernel means specifying its arguments, marshaled via an array of pointers:
CUresult cuLaunchKernel (
CUfunction f,
/* launch config stuff */,
void** kernelParams,
...