I have b number of blocks and each block has t number of threads. I can use
__syncthreads()
to synchronize the threads that are in a particular block. for example
__global__ void aFunction()
{
for(i=0;i<10;i++)
{
//execute something
__syncthreads();
}
}
But my problem is to synchronize all the threads in all the blocks. How can I do this?