Thanks to visit codestin.com Credit goes to github.com
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent f3f0492 commit a7de60eCopy full SHA for a7de60e
1 file changed
csrc/type_shim.h
@@ -362,8 +362,9 @@ __device__ __forceinline__ T reduce_block_into_lanes
362
if(tid < lanes)
363
x[tid] = final; // EpilogueOp
364
// Make sure the smem result is visible to all warps.
365
- __syncthreads();
366
}
+ __syncthreads();
367
+ // Avoid potential write before read race when reduce_block_into_lanes is called back to back
368
369
return final;
370
0 commit comments