Hi,
I am trying to develop an application where I need to refresh a buffer which the kernel is called with. I tried using asynch transfer with streams and double buffering… but I guess that its not possible to make a kernel use the refreshed state while in execution… I might be wrong but I feel async transfer helps only for D2H(device to host) transfers.
-
Does async transfer work only for D2H or vice-versa as well ? If it does, can I do the following :
Call_kernel<<<…,…,stream0>>>(d_a,d_b)
while( cudaEventQuery(stop) == cudaErrorNotReady )
{
cudaMemcpyAsync(d_a,&h_a,sizeof(int),cudaMemcpyHostToDevice,stream0);
} -
Is it possible to call cudaMemCpy() from CPU threads while kernel is in execution to do the same as above…
Please advise…
Thanks