[ROCm][Perf] Kimi-K3 Shard Latent MoE up-projection for ROCm path - #51253
Merged
Merged
Conversation
Signed-off-by: kliuae <kuanfu.liu@embeddedllm.com>
kliuae
requested review from
AndreasKaratzas,
DarkLight1337,
dllehr-amd,
hongxiayang,
tjtanaa and
ywang96
as code owners
August 6, 2026 10:51
Signed-off-by: kliuae <kuanfu.liu@embeddedllm.com>
|
✅ @kliuae, CI is now available for this PR.
|
tjtanaa
enabled auto-merge (squash)
August 7, 2026 04:51
Member
|
/ci run |
|
✅ Triggered Buildkite CI #82784 for commit |
Draft
4 tasks
zyp2014
pushed a commit
to zyp2014/vllm
that referenced
this pull request
Aug 21, 2026
…lm-project#51253) Signed-off-by: kliuae <kuanfu.liu@embeddedllm.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Purpose
For Kimi-K3, the default routed up-projection is a
ReplicatedLinearwhere every TP rank holds the same weight and computes idential full projection where only 1/8 of the work is needed. On the CUDA path, there isLatentMoERunnerthat shards the workload in a column parallel manner. However, currently the ROCm path lacks this and does not pass arunner_clsto theFusedMoeFactoryso it never reaches it.This PR adds a ROCm
LatentMoERunnercounterpart and the up projection sharding strategy, mirroring the CUDA path's Tier 2, to allow each rank to project only its slice of the hidden states and accumulate on the partial output. The GEMM's beta-add epilogue folds the two together and the final all-reduce stitches the routed shards when it reduces the shared output. This improves throughput by 3~5%.Test Plan
lm_eval with gsm8k on MI355X
Server command
Benchmark command
lm_eval command
Test Result
lm_eval gsm8k (PR)
20-shot
E2E performance on MI355X
Essential Elements of an Effective PR Description Checklist
supported_models.mdandexamplesfor a new model.