Skip to content

[AMD] DSv4.1-Flash MI355X vLLM DEP8 AgentX c256/c512/c1024 with tensor-scale FP8 KV cache / [AMD] DSv4.1-Flash MI355X vLLM DEP8 AgentX c256/c512/c1024 启用 tensor scale FP8 KV cache - #5056

Open
Fangzhou-Ai wants to merge 5 commits into
mainfrom
amd/dsv41flash-mi355x-vllm-dep8
Open

Fangzhou-Ai wants to merge 5 commits into
mainfrom
amd/dsv41flash-mi355x-vllm-dep8

Conversation

@Fangzhou-Ai

@Fangzhou-Ai Fangzhou-Ai commented Nov 13, 2026 •

Copy link
Copy Markdown
Collaborator

Adds DEP8 points for DeepSeek-V4.1-Flash FP4 AgentX on MI355X (vLLM) at concurrency 256, 512 and 1024: TP1 x DP8 with expert parallelism over the 8 ranks, experts on AITER MegaMoE over MoRI, behind a consistent-hash vLLM router. They live under a new config key, dsv41flash-fp4-mi355x-vllm-agentic-dspark-dep8, so the existing TP2/TP4 grid does not rerun. Prefill uses vLLM's existing cadence scheduling (prefill-schedule-interval 96, 32768-token budget, long-prefill-token-threshold 8192) with max-num-seqs 128 (160 at c1024), the scheduling knobs the B300 DEP8 recipe uses; the cross-DP delayer (vllm-project/vllm#65655) is not used. The KV cache is the per-tensor-scale FP8 format (--kv-cache-dtype fp8_e4m3, vllm-project/vllm#66036), included in the pinned image nightly-9bc16ae6a34b1e0fe260e8d12b98568478bf38c3, which also carries the MegaMoE wiring (vllm-project/vllm#66644) and the Engram peer-read fix (#66500).

Draft: nothing here has been swept. No CI run and no run link yet.

Local reference (not an InferenceX run). An earlier local one-hour AgentX c256 run on 8 x MI355X with MegaMoE + MoRI, cadence interval 96 and a 32768-token budget measured 174.3K tok/s/GPU, p90 interactivity 131.8, TTFT p50 2.28 s and p90 5.83 s. That run used a patched vLLM overlay on an older build, GPU-resident Engram tables and no FP8 KV cache, so it does not describe this config.

Risks and open items

  • max-num-seqs, the cadence interval and the long-prefill threshold are copied from the B300 recipe. The B300 recipe uses a 65536-token budget; this PR uses 32768, the value used in the local run above. c512 uses the 128 that B300 uses at its neighbouring points (384 and 544), since B300 has no c512 point.
  • Engram tables stay in HBM, sharded across the DP ranks (cpu_offload: false, embedding_across_dp: true), as in the B300 DEP8 recipe. With host offload the table sits in a small-page /dev/shm mapping and prefill Engram lookups took 54 to 110 ms per layer on MI355X ([ROCm][Perf][DSv4.1] Sort Engram host lookups by table offset on MI355X vllm-project/vllm#67805 fixes that path, but HBM tables avoid it). A local one-hour AgentX c256 run on 8 x MI355X with this setting (a vLLM worktree one commit after this image's, not the image itself) gave 182.7K tok/s/GPU, p90 interactivity 120.6, TTFT p50 1.80 s and p90 3.61 s, versus 175.6K, 96.4, 2.06 s and 4.41 s for host offload on this image's commit; single runs. c512 and c1024 were not run with HBM tables; the table costs about 12 GiB of HBM per rank, which comes out of the KV budget.
  • The vLLM router on the MI355X runner is not validated; the B300 recipe already uses the same setup.
  • MegaMoE on this image has not been run with kv-cache-dtype: fp8_e4m3.
  • Run the full sweep and evals.
Change details
中文

为 MI355X 上的 DeepSeek-V4.1-Flash FP4 AgentX(vLLM)新增 DEP8 点位,并发 256、512 和 1024:TP1 x DP8,专家在 8 个 rank 间做专家并行,专家计算使用基于 MoRI 的 AITER MegaMoE,前端使用一致性哈希的 vLLM router。点位放在新的配置键 dsv41flash-fp4-mi355x-vllm-agentic-dspark-dep8 下,不会重跑现有 TP2/TP4 网格。Prefill 使用 vLLM 现有的 cadence 调度(prefill-schedule-interval 96,32768 token 预算,long-prefill-token-threshold 8192),max-num-seqs 为 128(c1024 为 160),这些调度参数取自 B300 DEP8 配方;不使用跨 DP 的 delayer(vllm-project/vllm#65655)。KV cache 使用 per-tensor scale FP8 格式(--kv-cache-dtype fp8_e4m3,vllm-project/vllm#66036),已包含在固定镜像 nightly-9bc16ae6a34b1e0fe260e8d12b98568478bf38c3 中,该镜像同时包含 MegaMoE 接入(vllm-project/vllm#66644)和 Engram peer-read 修复(#66500)。

草稿:尚未运行任何 sweep。 目前没有 CI 运行,也没有运行链接。

本地参考(非 InferenceX 运行)。 此前在 8 卡 MI355X 上做过一小时 AgentX c256 本地测试(MegaMoE + MoRI,cadence interval 96,32768 token 预算),结果为 174.3K tok/s/GPU,p90 交互性 131.8,TTFT p50 2.28 s、p90 5.83 s。该测试使用较旧构建上的 vLLM 补丁 overlay、Engram 表放在 GPU 上且未启用 FP8 KV cache,因此不代表当前配置。

风险与待办

  • max-num-seqs、cadence interval 和 long-prefill 阈值取自 B300 配方。B300 使用 65536 token 预算,本 PR 使用 32768(与上述本地测试一致)。B300 没有 c512 点位,c512 使用 B300 相邻点位(384 和 544)的 128。
  • Engram 表保留在 HBM 中并在 DP rank 间分片(cpu_offload: false, embedding_across_dp: true),与 B300 DEP8 配方一致。主机卸载时表位于小页的 /dev/shm 映射中,MI355X 上 prefill 的 Engram 查找每层耗时 54 到 110 ms([ROCm][Perf][DSv4.1] Sort Engram host lookups by table offset on MI355X vllm-project/vllm#67805 修复了该路径,但 HBM 表可直接避开)。使用该设置在 8 卡 MI355X 上做了一小时 AgentX c256 本地测试(所用 vLLM worktree 比本镜像新一个提交,并非该镜像本身):182.7K tok/s/GPU,p90 交互性 120.6,TTFT p50 1.80 s、p90 3.61 s;对比本镜像对应提交上的主机卸载为 175.6K、96.4、2.06 s、4.41 s;均为单次运行。c512 和 c1024 未用 HBM 表运行;该表每个 rank 约占 12 GiB HBM,会从 KV 预算中扣除。
  • MI355X runner 上的 vLLM router 尚未验证;B300 配方已使用相同设置。
  • 该镜像上的 MegaMoE 尚未与 kv-cache-dtype: fp8_e4m3 一起运行过。
  • 运行完整 sweep 和评测。
AI model disclosure

Claude Sonnet 5.5 (claude-sonnet-5-5), run through Claude Code, prepared the config and recipe changes and wrote this description. No delegated agents.

🤖 Generated with Claude Code

… c1024 on MI355X

TP1 x DP8 with expert parallelism behind a consistent-hash router, cadence
prefill scheduling (no delayer) and the per-tensor-scale FP8 KV cache
(vllm-project/vllm#66036), on vLLM nightly-be47189f.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
…ints

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
@github-actions

Copy link
Copy Markdown
Contributor

Thanks for the contribution!

  • Review: If this PR changes files owned by someone other than a repository admin or @SemiAnalysisAI/core, ask one eligible CODEOWNER to complete the latest PR_REVIEW_CHECKLIST.md before contacting a core maintainer on Slack. Follow the template exactly, including As a PR reviewer and CODEOWNER, I have reviewed this and have, so sign-off verification triggers.
  • PR verification: Sweeps run only when the PR appends an inferencex-e2e/perf-changelog.yaml entry and carries exactly one primary label: full-sweep-fail-fast (strongly recommended; canary plus per-matrix fail-fast), full-sweep-enabled (canary; matrix jobs continue after a failure), or non-canary-full-sweep-enabled (no canary or fail-fast). The modifiers all-evals, evals-only, and agentx-fast require a primary label. On fork PRs, a maintainer applies the label. See sweep labels and reuse.
  • After merging: PR authors must ensure all GitHub Actions jobs pass. Transient failures often pass on rerun; see how to rerun failed jobs.
中文

感谢你的贡献!

  • **审阅:**如果 PR 修改的文件归属于仓库管理员及 @SemiAnalysisAI/core 之外的 CODEOWNER,请先联系一位有资格的 CODEOWNER 填写最新的 PR_REVIEW_CHECKLIST.md,再通过 Slack 联系核心维护者。必须严格遵循模板,并保留 As a PR reviewer and CODEOWNER, I have reviewed this and have,才能触发签核验证。
  • **PR 验证:**只有当 PR 在 inferencex-e2e/perf-changelog.yaml 末尾追加了条目,并且恰好带有一个主标签时,才会运行扫描:full-sweep-fail-fast(强烈推荐;canary 加逐矩阵 fail-fast)、full-sweep-enabled(有 canary;矩阵任务在失败后继续运行)或 non-canary-full-sweep-enabled(无 canary,也无 fail-fast)。修饰标签 all-evals、evals-only 和 agentx-fast 必须与主标签一起使用。fork PR 的标签由维护者添加。参见扫描标签与复用。
  • **合并后:**PR 作者必须确保所有 GitHub Actions 任务通过。临时性失败通常可以通过重新运行恢复;参见重新运行失败任务的说明。

…e DSv4.1-Flash DEP8 points

Cadence interval 96, max-num-seqs 128 (160 at c1024), long-prefill threshold 8192
and a 32768-token budget, with host-offloaded Engram tables.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
@Fangzhou-Ai
Fangzhou-Ai marked this pull request as ready for review November 13, 2026 01:29
@Fangzhou-Ai
Fangzhou-Ai requested a review from a team November 13, 2026 01:29
@Fangzhou-Ai Fangzhou-Ai added the non-canary-full-sweep-enabled Run the full sweep without the canary gate (full search space, no trim) label Nov 13, 2026
@claude

claude Bot commented Nov 13, 2026 •

Copy link
Copy Markdown
Contributor

Claude finished @Fangzhou-Ai's task in 54s —— View job


LGTM - no blocking issues found

What I checked
  • Variant selection: the existing dsv41flash-fp4-mi355x-vllm-agentic-dspark and -tp8-c1 keys use agentic.yaml with no selector. The new override_dep8_* blocks can't match their points: those points have dp-attn: false, ep: 1 and conc ≤ 64. So adding the new blocks doesn't make the existing points match more than one variant or change which variant they get.
  • Null handling: monokernel: null in a plain override_* block removes the base flag through deep_merge, as intended.
  • Router: vllm-router.sh is a known installer, and the 0.1.14 pin matches the B300 DEP8 entries.
  • Graph capture: max-cudagraph-capture-size: 1024 covers max-num-seqs × 6 tokens (5 DSpark drafts + 1): 768 at max-num-seqs 128 and 960 at 160.
  • Stream interval: not set, so it uses vLLM's default of 1, which is within the AgentX limit of 60.
  • Changelog and image: the perf-changelog.yaml entry is appended at the end of the file and covers the new key. The image is public Docker Hub, pinned by digest.
  • I couldn't run infx.matrix.changed; it needed approval in this environment. That check only matters when a PR has no changelog entry, and this one has one.

@claude claude Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nothing blocking. The comments below are optional suggestions. There is no need to push a fix for them before merging.

Comment on lines +960 to +961
# TP1 x DP8 with expert parallelism over the 8 ranks, behind a consistent-hash router so multi-turn
# sessions keep their prefix-cache hits.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 nit (optional): Maintainers get comments that AGENTS.md forbids. The comment above dsv41flash-fp4-mi355x-vllm-agentic-dspark-dep8 (amd-master.yaml:960) is a header that describes the topology. AGENTS.md bans those for configs, recipes and overrides. Fix: keep only the why, e.g. one line above router: saying consistent hashing keeps a multi-turn session's prefix-cache hits on one rank. Drop the "TP1 x DP8 with expert parallelism" topology text. Likewise "Mono decode is off for the data-parallel layout." (agentic.yaml:315, 352, 389) restates monokernel: null. It should say why mono decode cannot run at DP8, or be removed.

Why this was flagged

AGENTS.md "Comments (mandatory, every file)" says: "No header comments describing a file, topology, config, recipe, override, or section" and "never restate the code". The new comment at inferencex-e2e/configs/amd-master.yaml:960-961 opens with "TP1 x DP8 with expert parallelism over the 8 ranks". That restates the search-space row (tp: 8, ep: 8, dp-attn: true) and the recipe's parallel settings, so it is a topology header on a config key. In inferencex-e2e/benchmarks/single_node/srt-slurm-recipes/dsv41flash/vllm/mi355x-fp4-mtp/agentic.yaml:315, 352 and 389, "# Mono decode is off for the data-parallel layout." only says what monokernel: null does. It gives no reason, such as a kernel limit at DP or a measured failure. This is a convention slip, not a runtime failure. These comments are new in this diff, so the base branch does not have them.

Verification: AGENTS.md:54-58 says: "No header comments describing a file, topology, config, recipe, override, or section" and "never restate the code". The diff adds a header at inferencex-e2e/configs/amd-master.yaml:960-961 whose first clause, "TP1 x DP8 with expert parallelism over the 8 ranks", describes the topology. Nothing at runtime breaks.

@github-actions

github-actions Bot commented Nov 13, 2026 •

Copy link
Copy Markdown
Contributor

Fangzhou-Ai and others added 2 commits November 16, 2026 00:02
…o nightly-9bc16ae6

Use engram-config {"cpu_offload":false,"embedding_across_dp":true} at c256, c512 and
c1024, as the B300 DEP8 recipe does. Host-offloaded tables are read through small-page
host mappings, which made prefill Engram lookups 54 to 110 ms per layer on MI355X.

Move the image to vllm/vllm-openai-rocm:nightly-9bc16ae6 (index digest
sha256:1f70fc06f38a18ae5e6ba1e25d9f59fd6f9fd79080d03a6dfdbb84f2bca33052).

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Signed-off-by: Fangzhou Ai <fangzhou.ai@amd.com>
Resolve the perf-changelog.yaml conflict by keeping main's new entries and appending this PR's entry last.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Signed-off-by: Fangzhou Ai <fangzhou.ai@amd.com>

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

non-canary-full-sweep-enabled Run the full sweep without the canary gate (full search space, no trim)

Projects

Status: No status

Development

Successfully merging this pull request may close these issues.

1 participant