Repository navigation
perf(flydsl-moe): reduce a8w4 GEMM2 VGPR pressure for DSV4 - #4135
Merged
Merged
Conversation
…e to cut a8w4 reduce VGPR 219->184
…alving peak B live set (VGPR 184->168)
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.
Summary
This PR optimizes the FlyDSL MXFP4/MXFP8 MoE v2 GEMM2 down-projection path for DSV4 a8w4 reduce-mode shapes.
MXFP4_G2_INTER_MAXso small-intermediate shapes such as DSV4inter_dim=512can compile with a tighter K cap and hit a straight-line K=2 GEMM2 mainloop.bench_gemm12_v2_vs_baseline.pyto compare v2 GEMM1/GEMM2 launch latency and correctness against the tuned DSV4 baseline kernels.MXFP4_G2_INTER_MAX=512 python bench_gemm12_v2_vs_baseline.py --stage gemm2 --csv aiter/configs/model_configs/dsv4_fp8fp4_tuned_fmoe.csv --model-dim 7168 --inter-dim 512 -E 384 -k 6
Test Plan
FLYDSL_DUMP_IR=1 MXFP4_G2_INTER_MAX=512on DSV4 a8w4 shape:model_dim=7168, inter_dim=512, E=384, topk=6.baseline v2 219 VGPR, straight-line K2 184 VGPR, N-half B split 168 VGPR, with no spill.