A high-throughput and memory-efficient inference and serving engine for LLMs
Mirrored from https://github.com/tduncan-lum/Nvidia-Optimization-Stack---VLLM.git
Synced Nov 11, 15:00 UTC
[Refactor] Remove useless syncwarp (#30510)
Signed-off-by: yewentao256 <zhyanwentao@126.com>
Wentao Ye committed
Dec 11, 2025 at 17:43 UTC
61249b177de1566027fc74e9b51b45a4c973eb47
1 file changed
-5
csrc/moe/grouped_topk_kernels.cu
-5
@@ -481,8 +481,6 @@ __device__ void topk_with_k2(T* output, T const* input, T const* bias,
481
largest = value;
482
}
483
}
484
-
485
- __syncwarp(); // Ensure all threads have valid data before reduction
484
// Get the top2 warpwise
485
T max1 = cg::reduce(tile, largest, cg::greater<T>());
486
@@ -589,7 +587,6 @@ __global__ void group_idx_and_topk_idx_kernel(
587
int pre_count_equal_to_top_value = 0;
588
// Use loop to find the largset top_group
589
while (count_equal_to_top_value < target_num_min) {
592
- __syncwarp(); // Ensure all threads have valid data before reduction
590
topk_group_value = cg::reduce(tile, value, cg::greater<T>());
591
if (value == topk_group_value) {
592
value = neg_inf<T>();
@@ -644,10 +641,8 @@ __global__ void group_idx_and_topk_idx_kernel(
641
}
642
}
643
queue.done();
647
- __syncwarp();
644
// Get the topk_idx
645
queue.dumpIdx(s_topk_idx);
650
- __syncwarp();
646
}
647
648
// Load the valid score value