Hi all.
I use clGetProgramInfo like this :
I have only one device, but the first line returns 4 .
And the 2nd and 3rd clGetProgramInfo()s give np[0] and bn[0] only. np[1~3] and bn[1~3] are invalid values. If I change the 3rd param of the calls to "1", a CL_INVALID_VALUE error would occur.
Does Anybody know why ? What does the "4" mean ?
err=clGetProgramInfo(program,CL_PROGRAM_NUM_DEVICES,NULL,NULL,&numDevices); size_t *np =new size_t[numDevices]; err=clGetProgramInfo(program,CL_PROGRAM_BINARY_SIZES,numDevices,np,NULL); char * * bn= new char * bn[numDevices]; for (int i=0;i<numDevices;i++) bn=new char [np]; err=clGetProgramInfo(program,CL_PROGRAM_BINARIES,numDevices,bn,NULL);