cancel
Showing results for 
Search instead for 
Did you mean: 

OpenCL

dikobraz
Journeyman III

clGetKernelWorkGroupInfo fails with no device specified

The following call fails with CL_INVALID_DEVICE:

cl_kernel kernel = <create kernel somehow>

size_t     size;

clGetKernelWorkGroupInfo(kernel,

                         0, // if device is specified, everything is fine

                         CL_KERNEL_WORK_GROUP_SIZE,

                         sizeof(size_t),

                         &size,

                         0);

Even though associated program is build only for one device. Specifying device solves the probleb. Hope that helps.

0 Likes
Reply