Skip to content

[HIP] [FlyDSL] DeepSeek-V4.1-Flash: MegaMoEV2 DSpark draft BF16 return and small-input route, EP8 / EP4 small-input bucket tables, H64 attention scalar loads - #9076

Merged
valarLip merged 3 commits into
ROCm:mainfrom
yhl-amd:hyi/dsv41-mega-draft-bf16-tables
Dec 3, 2026

Conversation

@yhl-amd

@yhl-amd yhl-amd commented Dec 2, 2026

Copy link
Copy Markdown
Contributor

Summary

DeepSeek-V4.1-Flash on gfx950, three parts:

  1. MegaMoEV2: BF16 return for the DSpark draft MoE on every route. The draft MoE (128 routed experts, topk 3, shared expert computed apart) is now V41_FLASH_DRAFT_LAYOUTS on 1 / 2 / 4 / 8 ranks (= BF16_RETURN_LAYOUTS). On main its staged route's p2p_quant="auto" picked fp8_blockwise_1x32 from P2P_FP8_MIN_MTPR on, so the draft instance (prefill capacity) returned FP8 rows; the default MoE backend's MoRI combine returns BF16. For these layouts "auto" now resolves to "none" at every capacity (the FP8-only aligned-pair Stage2 gives way to the plain Stage2 of the same bucket); an explicit p2p_quant is kept.
  2. MegaMoEV2: the EP8 draft layout (8, 16, 5120, 2304) on the small-input route. It joins FUSED_LAYOUTS as a small-input-only layout (SMALL_M_ONLY_LAYOUTS, large_m_layout_mtpr(); MegaMoEV2 and LargeMRuntime give it no large-input kernel): up to 512 rows a rank it takes the small-input kernel, above that the staged route. Its tune is the 48-expert EP8 tune with bf16_rows_always (new FusedStage1Knobs field, default off): every rank sends BF16 GEMM2 rows. Fixed-slot dispatch as the 48-expert layout.
  3. MegaMoEV2: per-bucket small-input tables for EP8 / EP4 V4.1-Flash (A8W4 only).
    • EP8 (48 experts a rank): one CTA a CU at 8 and 16 tokens, en_order 7 at 16..256 tokens, 32 producer CTAs at 32 tokens.
    • EP4 (96 experts a rank): 32 producer CTAs (96 at 128 tokens), SGPR head pointers and en_order 7 at 32, 64, 128 tokens.
    • en_order (new FusedStage1Knobs field, default 0): GEMM1 (bit 1) / GEMM2 (bit 2) units of the run of one expert's m-tiles that lies wholly in an XCD's slice go in (expert, n)-major order; bit 4 reads those units' weights through the cache. A bijection on the units: every tile computes the same.
    • The tables change neither what the ranks exchange nor what a tile computes. bf16_rows_always / en_order reach the kernel factory only when set, so every other config keeps its kernel and AOT cache key. Other layouts (EP2, V4-Pro, A4W4, …) are unchanged.
  4. AOT: the default FlyDSL MegaMoE build also covers the draft MoE instances (EP8 / EP4 / EP2, MTPR 8192 / 16384 / 32768).
  5. fused_norm_rope_attn_rope_cast H64 (attention_64rows.cuh): CSR indptr / positions read through the constant address space (scalar loads, off the vmcnt queue); prepare_q_direct loads the RoPE coefficients of the rotated fragments outside the lane-divergent branch. Bit for bit the same outputs.

No new environment variables.

Validation

All on gfx950 (MI355X), FlyDSL 0.5.3.

Bit-exactness

  • MegaMoEV2 forward() of the V4.1-Flash target layouts, this branch (tables on) vs main, every route (staged / small-input / large-input, uneven and idle ranks, 2 layers): EP8 288/288 and EP4 144/144 rank outputs identical.
  • op_tests/multigpu_tests/test_mega_moe_v41.py --check tables: every case (uniform, hot-expert, Zipf routes at each table bucket) with and without the tables, bit for bit: EP8 38/38, EP4 20/20 PASS.
  • Attention: 5 shapes × 6 paths (base / mixed lengths / int32 positions / q_norm / pre-rotated / unaligned cos-sin) × splits 0/1/2 = 90 outputs, identical to main.

Draft BF16 return (test_mega_moe_v41.py --check draft, MTPR 16384)

  • EP8: configs (staged p2p_quant "none", no aligned pair, small-input bf16_rows_always on every bucket, no large-input kernel); small-input route vs staged route relL2 = 0.000000 on 12 uniform / skewed cases (including hot routes whose rank would pick FP8 rows by the rows it receives); relL2 vs the fp32 reference 0.052; staged calls 1..4096 rows 0.052 vs reference, 0.0267 away from an instance built with the FP8 return (FP8 return: 0.058 vs reference). 21/21 PASS.
  • EP4 / EP2 (staged only): 9/9 PASS each, same numbers.

AOT: after the FlyDSL MegaMoE replay of the draft (EP8 / EP4 / EP2, MTPR 16384) and target (EP8 / EP4, MTPR 8192 and 128) profiles, production instances launched at every small-input bucket and staged / large sizes with AITER_FLYDSL_AOT_RUNTIME_BUILD=0: 0 misses on all 7 profiles (an empty cache directory gives 40 on the same run).

Routes suite (test_mega_moe_v2.py --suite routes --network v41_flash --check-time-acc): EP8 and EP4 ALL PASS.

CPU tests (GPU hidden): tests/test_mega_moe_v41_draft_layout.py, tests/test_mega_moe_v41_small_knobs.py, tests/test_mega_moe_gfx950_route_plan.py, tests/test_aot_drivers.py, tests/test_flydsl_aot_cache.py, tests/test_flydsl_aot_launch.py: 357 passed, 1 skipped. The EP8 / EP4 V4.1-Flash pinned config digests are updated for the tables; bf16_rows_always / en_order enter the pinned tables only when set, so the other digests are unchanged.

With aiter#8878 (open, shared_in): this branch and #8878 merge without conflicts in either order; on the merged tree the routes suite with shared_in passes on EP8 (fused 59/59, 0 bad elements) and EP4 (30/30), and the tables / draft checks pass.

Performance (microbenchmark)

MegaMoEV2 small-input route, µs per layer call, CUDA-graph replays, 4 layers × 4 rotated weight copies, the tune without the table interleaved in the same process (2 + 2 rounds each), max over ranks; outputs bit-identical. "decode" = routes recorded from a DeepSeek-V4.1-Flash DEP8 decode step (EPLB placement), uniform / Zipf 1.2 / hot-expert are synthetic.

EP8 (8 ranks, 48 experts a rank):

rows/rank (bucket) decode uniform Zipf hot expert
8 (8) 67.6 → 52.0 (−23.1%) 105.8 → 105.5 (−0.4%) 129.4 → 129.7 (+0.2%) 73.2 → 56.9 (−22.4%)
16 (16) 71.5 → 63.2 (−11.5%) 131.9 → 136.6 (+3.6%) 155.0 → 154.9 (−0.1%) 85.2 → 79.3 (−6.8%)
36 (32) 92.1 → 91.9 (−0.2%) 160.7 → 160.5 (−0.1%) 181.4 → 170.5 (−6.0%) 122.9 → 117.2 (−4.7%)
48 (64) 96.7 → 96.4 (−0.3%) 165.2 → 165.2 (0.0%) 192.3 → 179.3 (−6.7%) 143.3 → 134.6 (−6.0%)
120 (128) 126.9 → 126.3 (−0.5%) 173.4 → 173.5 (+0.0%) 255.1 → 253.2 (−0.7%) 226.7 → 222.7 (−1.8%)
240 (256) 194.1 → 190.0 (−2.1%) 190.6 → 191.0 (+0.2%) 381.1 → 371.2 (−2.6%) 418.7 → 402.6 (−3.9%)

(At 120 / 240 rows the decode routes repeat the recorded step's rows.) Bucket 512 keeps the current tune: no candidate was ahead on all four route kinds.

EP4 (4 ranks, 96 experts a rank):

rows/rank (bucket) decode request-mixed decode uniform Zipf hot expert
36 (32) 105.8 → 99.4 (−6.1%) 223.9 → 223.8 (−0.1%) 277.3 → 276.6 (−0.3%) 283.0 → 273.6 (−3.3%) 124.2 → 108.2 (−12.9%)
60 (64) 121.4 → 118.6 (−2.3%) 261.5 → 261.3 (−0.1%) 303.0 → 303.2 (+0.1%) 330.4 → 310.0 (−6.2%) 158.0 → 150.6 (−4.7%)
120 (128) 160.3 → 155.9 (−2.7%) 304.0 → 304.1 (+0.0%) 311.8 → 311.8 (0.0%) 361.8 → 355.8 (−1.7%) 221.9 → 205.3 (−7.5%)

EP8 draft MoE: the small-input route replaces the staged route up to 512 rows a rank (same BF16 outputs).

Attention (fused_norm_rope_attn_rope_cast, H64, µs per call, main → this branch): 31.26 → 31.12, 27.76 → 27.59, 32.25 → 32.07, 25.01 → 24.83, 23.77 → 23.43 (5 decode shapes).

🤖 Generated with Claude Code

@yhl-amd
yhl-amd requested a review from a team December 2, 2026 12:46
@github-actions

github-actions Bot commented Dec 2, 2026

Copy link
Copy Markdown
Contributor

🏷️ CI Guide

Runs automatically on every PR:

  • ✅ Pre-checks (submodule verification, code formatting)
  • ✅ Aiter standard tests on MI35X
  • ✅ Triton tests on MI35X (only when aiter/ops/triton/** or related paths are changed)

Extended tests (opt-in via labels):

Label Tests
ci:mi300x Run Aiter standard tests on MI300X in PRs; main branch always runs them
ci:gfx1250-ffm-triton Run the five-shard gfx1250 FFM Triton test suite
ci:triton-300x Run an additional Triton test job on MI300X in PRs (added automatically when gfx942 configs change); main branch always runs both MI35X and MI300X
ci:triton-355 Run the full Triton test suite on MI35X, not only the tests the change affects
ci:windows Windows JIT op smoke test on the Radeon R9700 ROCm runner
ci:multi-gpu Aiter multi-GPU tests on the 8-GPU runner
ci:sglang SGLang integration tests: DeepSeek-R1-MXFP4 accuracy, Qwen 3.5 accuracy
ci:atom ATOM benchmark: DeepSeek-R1-0528, GPT-OSS-120B
ci:atom_full ATOM accuracy suite for PR and main models from ATOM models_accuracy.json
ci:vllm vLLM benchmark: DeepSeek-V4-Pro, MiniMax-M3-MXFP4
ci:all All standard extended tests (excludes ci:atom_full)

Only add ci:atom_full for FlyDSL or Triton upgrades.
Add labels via the sidebar or gh pr edit 9076 --add-label <label>

One backend per PR:
A PR changes one kernel backend: [Triton/Gluon] (Triton and Gluon count as one), [HIP], [ASM], [CK], [OPUS] or [FlyDSL]. If the title ends up with two backend tags, split the PR -- as stacked pull requests when one part cannot merge without the other.

PR title tags & labels:
Component tags ([Triton/Gluon], [HIP], [CK], [ASM], ...) are added to the PR title and as PR labels automatically from the changed files and re-synced on every push — change-type tags like [fix]/[Perf], op tags like [MLA], and human labels (ci:*) are left untouched. Add the no-auto-title label to stop the title rewrites; labels stay in sync either way.

Reviews:
A reviewer is usually assigned within one working day after the PR is ready for review (see Code Review Process). If nobody has responded for about a week, mention the area contact listed in CONTACTS.md. Want to help review? See REVIEWERS.md.

@github-actions github-actions Bot changed the title [FlyDSL] [HIP] DeepSeek-V4.1-Flash: MegaMoEV2 DSpark draft BF16 return and small-input route, EP8 / EP4 small-input bucket tables, H64 attention scalar loads [HIP] [FlyDSL] DeepSeek-V4.1-Flash: MegaMoEV2 DSpark draft BF16 return and small-input route, EP8 / EP4 small-input bucket tables, H64 attention scalar loads Dec 2, 2026
@aiter-bot

aiter-bot commented Dec 2, 2026 •

Copy link
Copy Markdown

WAITING ON AUTHOR

PR Self-Review

Revision 3b3d6f6cdc4b · mode shadow

Waiting for the PR author. The readiness report will appear after the self-review answers are complete for this revision.

Questions to answer in the PR description

  1. What behavior does this PR change, and why is the existing behavior insufficient?
  2. What did you validate, and what remains unverified? Include commands, hardware/configuration and results.
  3. Which architecture, dtype and shape boundaries select the changed kernel path, and what invariant prevents unsupported inputs from reaching it?
  4. For every changed op_tests/ file, what behavior does it cover and why is it not redundant? Write None if no op test changed.

Edit the PR Self-Review section in the PR description. Include the current revision SHA; this comment refreshes automatically.

Missing or invalid answers

  • FAIL — missing ### Reviewed revision in the PR description
  • FAIL — missing ### Behavior and intent in the PR description
  • FAIL — missing ### Validation and unverified scope in the PR description
  • FAIL — missing ### PR-specific question in the PR description
  • FAIL — missing ### Changed op tests in the PR description
  • FAIL — Reviewed revision must contain at least the first 7 characters of the current head SHA
  • FAIL — Behavior and intent has no substantive answer
  • FAIL — Validation and unverified scope has no substantive answer
  • FAIL — PR-specific question has no substantive answer
  • FAIL — changed op test not explained in Changed op tests: op_tests/multigpu_tests/test_mega_moe_v41.py
  • FAIL — Changed op tests must explain why each changed op test is necessary and non-redundant

Shadow mode reports what would block but keeps the status successful. Set AITER_PR_SELF_REVIEW_MODE=enforce only after reviewing real false positives.

@yhl-amd yhl-amd closed this Dec 2, 2026
@yhl-amd yhl-amd reopened this Dec 2, 2026
yhl-amd and others added 2 commits December 3, 2026 01:05
…aft MoE, its EP8 small-input route, EP8 / EP4 small-input bucket tables

DSpark draft MoE (128 routed experts, topk 3, the shared expert computed apart):

- Every route returns BF16 rows, the precision of the default MoE backend's
  MoRI combine. V41_FLASH_DRAFT_LAYOUTS lists the draft MoE on 1, 2, 4 and 8
  ranks; BF16_RETURN_LAYOUTS is that set. The staged route's p2p_quant "auto"
  resolves to "none" at every capacity for them (it picked fp8_blockwise_1x32
  from P2P_FP8_MIN_MTPR, i.e. at the draft instance's prefill capacity), and
  the FP8-only aligned-pair Stage2 gives way to the plain Stage2 of the same
  bucket. An explicit p2p_quant is kept.
- The EP8 layout (8, 16, 5120, 2304) is a fused layout of the small-input
  kernel only (SMALL_M_ONLY_LAYOUTS; large_m_layout_mtpr() gives it no
  large-input capacity, MegaMoEV2 and LargeMRuntime skip it): calls up to 512
  rows a rank take the small-input route, larger ones the staged route. Its
  tune is the 48-expert EP8 small-input tune with bf16_rows_always
  (FusedStage1Knobs, default off): every rank sends BF16 GEMM2 rows instead of
  the rows-received choice of FP8 or BF16 rows. The small-input kernel
  dispatches it into fixed slots, as the 48-expert layout.
- The target-model layouts keep every config field.

EP8 / EP4 V4.1-Flash small-input bucket tables (A8W4, their layouts only):

- _V41_FLASH_EP8_SMALL_KNOBS: one CTA a CU at 8 and 16 tokens, en_order 7 at
  16 to 256 tokens, 32 producer CTAs at 32 tokens.
- _V41_FLASH_EP4_SMALL_KNOBS: 32 producer CTAs (96 at 128 tokens), SGPR head
  pointers and en_order 7 at 32, 64 and 128 tokens.
- en_order (FusedStage1Knobs, default 0): the GEMM1 (bit 1) and GEMM2 (bit 2)
  units of the run of one expert's m-tiles that lies wholly in an XCD's slice
  go in (expert, n)-major order; bit 4 reads those units' weights through the
  cache. A bijection on the units: every tile computes as before.
- The knobs change neither what the ranks exchange nor what a tile computes;
  the outputs are those of the configs without the tables, bit for bit.
  bf16_rows_always and en_order reach the kernel factory only when set, so the
  other configs keep their kernels and cache keys.

AOT: the default FlyDSL MegaMoE build also covers the draft MoE instances
(EP8 / EP4 / EP2, MTPR 8192, 16384 and 32768).

Tests:
- tests/test_mega_moe_v41_draft_layout.py: layout gate, no large-input
  capacity, the route for every max_tokens, the small-input configs, one
  launch protocol, the staged BF16 return at every capacity on every EP width,
  the target layouts' returns unchanged, fixed-slot dispatch.
- tests/test_mega_moe_v41_small_knobs.py: the tables set only schedule knobs,
  change only their buckets, keep one launch protocol, leave A4W4, EP2 and
  V4-Pro alone; the new knobs reach the factory only when set.
- tests/test_mega_moe_gfx950_route_plan.py: pinned digests of the EP8 / EP4
  V4.1-Flash fused configs updated for the tables (bf16_rows_always and
  en_order enter the pinned table only when set).
- tests/test_aot_drivers.py: the draft profiles.
- op_tests/multigpu_tests/test_mega_moe_v41.py: --check draft (configs, the
  small-input route against the staged route and the fp32 reference on
  uniform and skewed routes, staged calls against the reference, an FP8-return
  instance told apart) and --check tables (every case with and without the
  tables, bit for bit), on 8 / 4 / 2 ranks.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
…CSR indptr / positions as scalar loads

attention_64rows.cuh, bit for bit the outputs before:

- The CSR indptr and positions reads are kernel-invariant and wave-uniform:
  load_uniform() reads them through the constant address space, so they are
  scalar loads (lgkmcnt) instead of vector loads that sit in the in-order
  vmcnt queue behind the large Q / row-index loads.
- prepare_q_direct loads the RoPE coefficients of the two rotated fragments
  once per lane, outside the lane-divergent branch (16-byte loads when cos /
  sin are aligned), and selects the rotated or unrotated values per lane.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@yhl-amd
yhl-amd force-pushed the hyi/dsv41-mega-draft-bf16-tables branch from 55a019f to 60f9646 Compare December 2, 2026 17:05
@valarLip
valarLip merged commit ed1163f into ROCm:main Dec 3, 2026
53 of 56 checks passed
Yaowu-Xiong added a commit that referenced this pull request Dec 3, 2026
Conflicts with #9076 (DeepSeek-V4.1-Flash DSpark draft layouts, EP8 / EP4
small-input bucket tables), resolved by keeping both sides:

- mega_moe_config.py: the EP8 hidden-7168 large_m tune next to main's
  bucket tables and draft tune. The EP8 small-input bucket table applies to
  the V4.1-Flash EP8 layout only, so Kimi-K2.6 A8W4 keeps the EP8
  V4.1-Flash tune without it, as before the merge.
- mega_moe_large_m.py: the LargeMRuntime layout error names both the K2.6
  layout and main's small-input-only layouts.
- aot/flydsl/mega_moe.py: the K2.6 jobs next to main's draft jobs.
- tests: the AOT job count (main's 66 plus 3 K2.6 jobs); the K2.6 small_m
  check compares against the EP8 V4.1-Flash tune without its table.

Kimi-K2.6 and DeepSeek-V4-Pro select the same configs as before the merge, and
their AOT kernels are byte-identical (except the nondeterministic prepare
kernels); against main only V4-Pro A8W4 large_m at MTPR 1024..16384 differs,
as before.

Co-authored-by: Cursor <[email protected]>
seungrokj added a commit to SemiAnalysisAI/InferenceX that referenced this pull request Dec 3, 2026
- Update the image from rocm/atom-dev:nightly_202611101510 (ATOM e5b74bc86) to nightly_202612031117@sha256:ef8293cd19b40344b4e755f7b0934bb961c4ee8e844758b7de84a7ce5e8cf7b9 (ATOM 10e8c1ea6, AITER ed1163f82, Mooncake 206d6340, ROCm 7.2.4) in the master config, and the AToMesh frontend container_image from sha256:160a4ec49379e7f1980a4e783254366b1d5c643b012abca57a21c0bcbbfe83a7 to the same tag and digest.
- Replace plain TP2 at concurrency [1, 2, 16, 32], DTP2 (DP attention) at 64, DEP2 (DP attention plus expert parallelism) at [128, 256] and plain TP4 at [1, 2, 4, 8, 32] with plain TP8 at [1, 2, 4], plain TP4 at [4, 8, 16, 32], DEP4 at 64 and DEP8 at [128, 256, 384, 512]. Every TP2, DTP2 and DEP2 point and TP4 c1 and c2 are dropped; TP8 c1, c2 and c4, TP4 c16, DEP4 c64 and DEP8 c128 to c512 are new.
- TP8 c1 runs max-num-seqs 2, decode graphs [1, 2] and ATOM_PREFILL_DECODE_INTERVAL=1000000, and TP8 c2 and c4 run ATOM_PREFILL_DECODE_INTERVAL=192, the settings TP2 and TP4 used at those concurrencies. TP4 c4 (192) and c32 (16) are unchanged; TP4 c8 moves from the MXFP8 to a BF16 KV cache (interval 192), and the new TP4 c16 also runs a BF16 KV cache with interval 96.
- DEP8 runs MegaMoE (moe-backend mega) with AITER_MEGA_SHARED_IN=1, adaptive prefill admission, 4 API servers, share_cache DP routing with lockstep placement (--dp-share-cache-lockstep), online EPLB without redundant experts (load window 200, rebalance interval 800, 4 layers per chunk), decode graphs 1 to 48 plus 56, 64, 72, 80, 96 and 128, ATOM_PREFILL_DECODE_INTERVAL=0, ATOM_DP_SESSION_AFFINITY=0, ATOM_DP_LB_REQ_EQUIV=512, ATOM_FRONTEND_PREFIX_HASH=1, ATOM_DP_LM_HEAD_MODE=off, ATOM_GRAPH_SIDE_STREAMS=0, GPU_MAX_HW_QUEUES=5 and MORI_SHMEM_HEAP_SIZE=16G.
- DEP8 offloads KV to CPU DRAM (kv-offloading dram) through ATOM_KV_OFFLOAD=mooncake_store: a Mooncake master and two NUMA-bound 256 GiB Mooncake Store owners on rdma0-7 of the inference node, 1024 MiB load and 256 MiB save pools, OFFLOAD_MIN_LOAD_TOKENS and OFFLOAD_MIN_SAVE_TOKENS 512, OFFLOAD_MAX_PENDING_SAVES 8, one QP per endpoint, destination-device affinity, the memlock soft limit raised to the hard limit before the worker starts and a 3600 s health-check window.
- DEP4 c64 runs the DEP8 settings on 4 GPUs with 2 API servers and two 128 GiB Store owners. The DP points no longer use least_tokens routing, session affinity or the X-Dynamo-Session-Id header from AIPerf.
- Framework changes in the new ATOM that matter here: share_cache lockstep DP placement (ROCm/ATOM#3837, opt-in since #4074), adaptive prefill admission (#3647), the target shared expert handed to the MegaMoE routed call through AITER shared_in (#3894) with its MXFP8 input taken from the FFN seam (#3940), one-launch MegaMoE decode routing including the 48-expert layout (#3938) and route selection (#3187), EPLB on the pre-decoder layers and empty-window skip (#3186, #3952), the DSpark draft tail and DP-sharded draft argmax (#4104, #3939), ATOM_DP_LM_HEAD_MODE and the idle-rank LM head (#3353, #4025), and event-driven Store loads with a failed-save retry cap (#3772, #3781); AITER ed1163f82 (ROCm/aiter#9076) returns BF16 from the DSpark draft MegaMoE.
- Draft data type unchanged: the DSpark draft (mtp.0-2 in the target checkpoint) runs as shipped at both images, with FP8 E4M3 32x32 UE8M0 block-scaled attention, shared-expert and main_proj weights run as MXFP8, MXFP4 routed experts with MXFP8 activations (a8w4, through MegaMoE at DEP4 and DEP8), and BF16 gate, norms and the shared LM head. The draft attends in BF16 over the target's KV pool, which is MXFP8 except at TP4 c8 and c16 (BF16).

- 镜像从 rocm/atom-dev:nightly_202611101510(ATOM e5b74bc86)更新为 nightly_202612031117@sha256:ef8293cd19b40344b4e755f7b0934bb961c4ee8e844758b7de84a7ce5e8cf7b9(ATOM 10e8c1ea6、AITER ed1163f82、Mooncake 206d6340、ROCm 7.2.4),用于 master 配置;AToMesh 前端 container_image 从 sha256:160a4ec49379e7f1980a4e783254366b1d5c643b012abca57a21c0bcbbfe83a7 改为同一标签和 digest。
- 用 TP8 [1, 2, 4]、TP4 [4, 8, 16, 32]、DEP4 64 和 DEP8 [128, 256, 384, 512] 替换 TP2 [1, 2, 16, 32]、DTP2(DP attention)64、DEP2(DP attention 加专家并行)[128, 256] 和 TP4 [1, 2, 4, 8, 32]。所有 TP2、DTP2、DEP2 点以及 TP4 c1、c2 被移除;TP8 c1、c2、c4,TP4 c16,DEP4 c64 和 DEP8 c128 到 c512 为新增。
- TP8 c1 使用 max-num-seqs 2、decode 图 [1, 2] 和 ATOM_PREFILL_DECODE_INTERVAL=1000000,TP8 c2、c4 使用 ATOM_PREFILL_DECODE_INTERVAL=192,即 TP2 和 TP4 在这些并发下原来的设置。TP4 c4(192)和 c32(16)不变;TP4 c8 的 KV cache 从 MXFP8 改为 BF16(interval 192),新增的 TP4 c16 同样使用 BF16 KV cache,interval 96。
- DEP8 使用 MegaMoE(moe-backend mega)并设置 AITER_MEGA_SHARED_IN=1,自适应 prefill 准入,4 个 API server,带 lockstep 放置的 share_cache DP 路由(--dp-share-cache-lockstep),无冗余专家的在线 EPLB(load window 200、rebalance interval 800、每块 4 层),decode 图 1 到 48 加 56、64、72、80、96、128,ATOM_PREFILL_DECODE_INTERVAL=0、ATOM_DP_SESSION_AFFINITY=0、ATOM_DP_LB_REQ_EQUIV=512、ATOM_FRONTEND_PREFIX_HASH=1、ATOM_DP_LM_HEAD_MODE=off、ATOM_GRAPH_SIDE_STREAMS=0、GPU_MAX_HW_QUEUES=5 和 MORI_SHMEM_HEAP_SIZE=16G。
- DEP8 通过 ATOM_KV_OFFLOAD=mooncake_store 将 KV 卸载到 CPU DRAM(kv-offloading dram):推理节点上一个 Mooncake master 和两个绑定 NUMA 的 256 GiB Mooncake Store owner(rdma0-7),1024 MiB 加载池和 256 MiB 保存池,OFFLOAD_MIN_LOAD_TOKENS 和 OFFLOAD_MIN_SAVE_TOKENS 为 512,OFFLOAD_MAX_PENDING_SAVES 为 8,每个端点一个 QP,目标设备亲和,worker 启动前把 memlock 软限制提升到硬限制,健康检查窗口 3600 秒。
- DEP4 c64 在 4 张 GPU 上使用 DEP8 的设置,2 个 API server 和两个 128 GiB Store owner。DP 点不再使用 least_tokens 路由、会话亲和性或 AIPerf 的 X-Dynamo-Session-Id 头。
- 新 ATOM 中与本模型相关的框架变化:share_cache lockstep DP 放置(ROCm/ATOM#3837,自 #4074 起需显式开启)、自适应 prefill 准入(#3647)、目标层共享专家经 AITER shared_in 交给 MegaMoE 路由调用(#3894),其 MXFP8 输入取自 FFN 接缝(#3940)、单次启动的 MegaMoE decode 路由(含 48 专家布局,#3938)和路由选择(#3187)、decoder 之前层的 EPLB 和空窗口跳过(#3186、#3952)、DSpark draft 尾部与 DP 分片 draft argmax(#4104、#3939)、ATOM_DP_LM_HEAD_MODE 与空闲 rank 的 LM head(#3353、#4025)、事件驱动的 Store 加载和失败保存重试上限(#3772、#3781);AITER ed1163f82(ROCm/aiter#9076)使 DSpark draft MegaMoE 返回 BF16。
- Draft 数据类型不变:DSpark draft(目标 checkpoint 中的 mtp.0-2)在新旧镜像上都按发布精度运行,FP8 E4M3 32x32 UE8M0 块缩放的 attention、共享专家和 main_proj 权重以 MXFP8 运行,MXFP4 路由专家配 MXFP8 激活(a8w4,DEP4 和 DEP8 经 MegaMoE),BF16 的 gate、norm 和共享 LM head。draft 在目标的 KV 池上以 BF16 做 attention,该 KV 池除 TP4 c8 和 c16(BF16)外均为 MXFP8。

Co-Authored-By: Claude Opus 5.5 <[email protected]>
gyohuangxin pushed a commit that referenced this pull request Dec 4, 2026
…Rs (#9202)

* [CI] Skip torchrun CLI test in Multi-GPU suite; auto-label multigpu PRs

test_mega_moe_v41.py (#9076) requires --check {draft,tables} and is meant
to be run via torchrun, so the bare python3 invocation in aiter_test.sh
fails with argparse exit 2. Skip it in the bulk Multi-GPU run, like
test_mori_smoke.py.

Add actions/labeler to auto-apply ci:multi-gpu when a PR touches
op_tests/multigpu_tests/**, so the Multi-GPU lane runs on such PRs
instead of leaking failures to main.

Co-Authored-By: Claude Code <[email protected]>

* [CI] Fix labeler workflow: contents:read, fork guard, no label sync

- permissions: add contents: read — the job has no checkout step, so
  actions/labeler fetches .github/labeler.yml via the contents API, and a
  permissions block that names any scope sets unlisted scopes to none;
  without it every run 403s and no label is ever applied
- gate the job on non-fork PRs — fork PRs get a read-only GITHUB_TOKEN on
  pull_request events, so the add-label call would 403 with a red X
- sync-labels: false — sync would strip a manually-added ci:multi-gpu on
  PRs not touching op_tests/multigpu_tests/**, killing the in-flight
  multi-GPU run (aiter-test.yaml re-checks the label after the build)
- add trailing newlines to both new files, matching repo convention

Co-Authored-By: Claude Code <[email protected]>

---------

Co-authored-by: zufayu <[email protected]>
Co-authored-by: Claude Code <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants