add A4W4 and FP8 P2P transport support to MegaMoE v2 - #972
Open
Yaowu-Xiong wants to merge 6 commits into
Open
Conversation
Extend the fused operator to A4W4 and reduce Stage2 transport cost with quantized scatter, paired configuration tuning, and regression coverage.
Keep the MegaMoE feature branch scoped to APIs used by the implementation.
Use MegaMoE as the canonical public and internal name, and align the kernel test path and CI references with the unversioned operator.
Resolve MegaMoE conflicts while retaining A4W4 and configurable FP8 P2P support alongside upstream dispatch, tuning, and SwiGLU fixes. Co-authored-by: Cursor <cursoragent@cursor.com>
Restore A4-specific Stage2 pipeline and geometry choices while keeping P2P auto-selection rank-invariant. Co-authored-by: Cursor <cursoragent@cursor.com>
Restore tuned medium-batch FP8 profiles and honor the two-stage B pipeline to recover performance after merging main. Co-authored-by: Cursor <cursoragent@cursor.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.
Motivation
Extend MegaMoE V2 to support the DeepSeek V4 Pro A4W4 path alongside A8W4, while reducing Stage2 cross-rank traffic and latency with blockwise FP8 P2P scatter.
Technical Details
fp8_blockwise_1x32Stage2 transport:Test Plan
fp8_blockwise_1x32P2P transport for both A4W4 and A8W4.Test Result
8× AMD Instinct MI355X DeepSeek V4 Pro
hidden/intermediate:7168/3072 , experts/top-k:384/6 .
A4W4:V1 与 V2 BF16-P2P transport:

V2 A4W4:FP8-P2P 与 BF16-P2P

V2 A8W4:FP8-P2P 与 BF16-P2P

Submission Checklist