I have the following kernel
_global_ void func( float * arr, int N ) {
int rtid = blockDim.x * blockIdx.x + threadIdx.x; if( rtid < N ) { float* row = (float*)((char*)arr + rtid*N*sizeof(float) ); for (int c = 1; c < N; ++c) { //Manipulation } } }
When I call the kernel from MATLAB using
gtm= parallel.gpu.GPUArray(ones(a,b,'double')); OR gtm= parallel.gpu.GPUArray(ones(1,b,'double'));
gtm=k.feval(gtm,b);
it is giving the following error:
Error using ==> fevalparallel.gpu.GPUArray must match the exact input type as specified on the kernelprototype.
Error in ==> sameInit at 65 gtm=k.feval(gtm,b);
Can someone please tell me where am I going wrong.
Thanking You, Viharri P L V.
Best Answer