Skip to content

[Perf][DSV4.1] Enable the fused all-reduce + mHC boundary at TP2 - #60355

Open
andakai wants to merge 1 commit into
vllm-project:mainfrom
andakai:feat/fuse_allreduce_mhc
Open

andakai wants to merge 1 commit into
vllm-project:mainfrom
andakai:feat/fuse_allreduce_mhc

Conversation

@andakai

@andakai andakai commented Oct 7, 2026

Copy link
Copy Markdown
Contributor

Motivation

The fused CuTe DSL Lamport all-reduce + mHC post/collapse/RMSNorm (#57643, #58586) only runs at TP4. The Blackwell single-node recipes now default to TP2 (vllm-project/recipes#1002), so at TP2 every small-batch sublayer boundary still runs a separate all-reduce plus unfused mHC. The kernel is already parametrized by the TP world size, so this PR admits TP2 in supports_mhc_all_reduce (TP8 stays off) and extends the tests to TP2.

Evaluation

Setup: 2 × GB200, DeepSeek-V4.1-Flash

Correctness

  • GSM8K (5-shot, 1319 questions): main 0.901, this PR 0.901.

Performance: vllm bench serve, random dataset, ISL 1024 / OSL 512, no speculative decoding, mean of 3 seeds.

Concurrency TPOT p50 (ms) main → PR Output tok/s main → PR
1 5.19 → 4.48 (−13.8%) 184.6 → 213.0 (+15.4%)
2 5.58 → 4.93 (−11.7%) 347.7 → 390.7 (+12.4%)
4 6.10 → 5.25 (−13.9%) 607.2 → 701.5 (+15.5%)
8 6.86 → 6.08 (−11.3%) 1092.2 → 1212.9 (+11.1%)
16 8.48 → 7.64 (−9.9%) 1767.1 → 1919.2 (+8.6%)
32 10.59 → 10.55 (−0.4%) 2786.3 → 2658.8 (−4.6%, one outlier run)
64 13.44 → 13.72 (+2.1%) 4364.5 → 4346.2 (−0.4%)

Swapping the two arms' GPUs (and NUMA nodes) gives the same picture: TPOT changes by −12.1%, −13.9%, −10.8% and +0.7% at C1, C4, C16 and C64. TTFT is unchanged.

With DSpark (recipe default, k=5):

Concurrency ITL p50 (ms) main → PR Output tok/s main → PR
1 7.12 → 6.49 (−8.8%) 616.7 → 680.6 (+10.4%)
2 8.37 → 7.27 (−13.2%) 986.9 → 1149.0 (+16.4%)
4 9.63 → 8.33 (−13.6%) 1423.3 → 1497.0 (+5.2%)

At C≥8, DSpark steps exceed the 16-token fused limit, so the fused path is not taken.

Notes

🤖 Generated with Claude Code

The CuTe DSL Lamport all-reduce fused with mHC post, collapse and RMSNorm
(and the MoE finalize publish) is parametrized by the TP world size, but
supports_mhc_all_reduce only admitted TP4. The Blackwell single-node TP
recipes now default to TP2, where every sublayer boundary at <=16 tokens
fell back to a separate all-reduce plus the unfused mHC post and pre.

Admit TP2 and extend the kernel-vs-unfused test to TP2.

Signed-off-by: Dakai An <dakaian108@gmail.com>

@claude claude Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Claude Code Review

This pull request is from a fork — automated review is disabled. A repository maintainer can comment @claude review to run a one-time review.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

deepseek Related to DeepSeek models DSv4.1 Related to DeepSeek-V4.1 models

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant