In the manual of CUDA, in the explaination of cudaStreamSynchronize, it mentioned that
cudaStreamSynchronize
Blocks until stream has completed all operations. If