hello

i am new in openCL, i am trying to create a program - the knns algorithm, and i want to use 2 kernels which i want to be in depended . So i create a document knnsOpenCL.c and 2 kernel_createDist.cl and kernel_ParallelSorting.cl, the first one i already be executed, and now i have problem with the second!

in my main i create a device and a context, i also have 2 different build_program for each kernel

and the problem is tha i have the bug Couldn't create a kernel 2 ---> -46 ----> which is CL_INVALID_KERNEL_NAME

so i am wondering what is the exact problem! i don't know if i should create 2 devices?

i hope i find the answer here! any ideas?