Repository navigation
ad Gemm a8w8 tune - #25
Merged
Merged
Conversation
valarLip
approved these changes
Dec 18, 2024
Jasen2201
added a commit
to Jasen2201/aiter
that referenced
this pull request
Dec 19, 2025
valarLip
pushed a commit
that referenced
this pull request
Mar 18, 2026
* add gemm_a8w8_tune * add readme
Fangzhou-Ai
pushed a commit
to Fangzhou-Ai/aiter
that referenced
this pull request
Aug 27, 2026
Add dsv4_pro_0813_a8w8_blockscale config
1 task done
luocheng25
pushed a commit
to luocheng25/aiter
that referenced
this pull request
Nov 11, 2026
* fused_moe: opt-in FlyDSL GateUp + Down for gfx942 FP8 block-scale MoE AITER_FMOE_FP8_BLOCKSCALE_FLYDSL=1 routes the gfx942 per_1x128 FP8 g1u1 SiLU MoE (BF16 output, routing weights applied in Down) from the 1-stage asm fmoe_fp8_blockscale_g1u1 to the pyhip FlyDSL pipeline (pyhip.contrib.flydsl.moe_a8w8_blockscale_gfx942: GateUp 2x4 with FP8 sorted-row output, Down 4x2 storing single-route tokens). The check sits in _fused_moe_impl before the tuned-config lookup and moe_sorting: the pipeline needs a block-256 sort that leaves the output alone. Anything it does not cover falls back to the default path with one warning per reason: other gfx/quant/activation, bias, padding, swiglu_limit, a2_scale, stage2_scatter, internal overrides, static activation scales, fewer tokens than AITER_FMOE_FP8_BLOCKSCALE_FLYDSL_MIN_TOKENS (default 4096), pyhip not importable, or a shape the kernels do not support. Both EP styles work. expert_mask, num_local_tokens and the dispatch policy go to moe_sorting. FP8 input (MORI FP8 dispatch) needs a token-major a1_scale, transposed with the buffer row count as the stride (partial_transpose would use num_local_tokens). output= is written in place and rows past num_local_tokens are left untouched. MI300X, one EP8 rank of MiMo-V2.6-Flash, random top-8, whole fused_moe call against the default (untuned) asm path: 32768-token EP group (21667 received tokens) 3220 -> 1941 us (1.66x), 16384 1.59x, 8192 1.35x, 4096 1.14x, 2048 0.79x; all 32768 tokens local with BF16 input 1.62x. calc_diff 2.6e-6 vs 1.3e-5 for asm. Tests: pyhip tests/contrib/moe/test_aiter_fused_moe_flydsl_gfx942.py. Open gaps: - The sorted FP8 intermediate must fit one 2 GiB buffer descriptor: above ~130K rows (I = 2048, e.g. an untrimmed MORI receive buffer of 8 x 16384) the call falls back to asm. - ~570 MB extra workspace per call at 32K rows; the asm kernel has none. - The first call per process compiles (or loads) four FlyDSL kernels: warm up at startup. - The pyhip kernels use FlyDSL 0.4.0 while aiter pins 0.3.4.1. - Validated on MI300X (304 CUs) only; not tested under CUDA graph capture. * fused_moe: FlyDSL gfx942 FP8 block-scale hook falls back on a pre-transposed a1_scale This branch's fused_moe takes a1_scale_is_transposed; the hook expects token-major [tokens, H/128] scales.
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.
No description provided.