Skip to content

[AMD] [AgentX] dsv4-fp4-mi355x-vllm-agentic-mtp, update image and extend the DP-attention concurrency curve - #2590

Open
jiacao-amd wants to merge 3 commits into
mainfrom
jiacao/dsv4-agentic-mtp-0809-nopatch
Open

[AMD] [AgentX] dsv4-fp4-mi355x-vllm-agentic-mtp, update image and extend the DP-attention concurrency curve #2590
jiacao-amd wants to merge 3 commits into
mainfrom
jiacao/dsv4-agentic-mtp-0809-nopatch

Conversation

@jiacao-amd

@jiacao-amd jiacao-amd commented Aug 13, 2026

Copy link
Copy Markdown
Collaborator

Summary

Update the dsv4-fp4-mi355x-vllm-agentic-mtp image to vllm/vllm-openai-rocm:nightly-f8d03e77416bf90c49acbe50e233275722f02c4b and complete the DP-attention half of the concurrency curve. MI355X, 8 GPU, FP4 vLLM, deepseek-ai/DeepSeek-V4-Pro, agentic-coding trace replay with MTP (acceptance length 2.49).

Arms

arm tp ep dp-attn conc-list
pure TP8 8 1 false 1, 4, 8, 16, 32, 40, 48
dpatpa 8 1 true 32, 48, 64, 96

Changes

  • configs/amd-master.yaml: update the pinned image; extend the dp-attn arm from one point to four.
  • benchmarks/single_node/agentic/dsv4_fp4_mi355x_vllm_mtp.sh: under DP-attention cap --max-num-seqs at CONC (the limit is per scheduler) and set --max-num-batched-tokens 8192, --prefill-schedule-interval 8, --long-prefill-token-threshold 16384; export VLLM_ROCM_USE_AITER_FUSION_SHARED_EXPERTS=1; raise --gpu-memory-utilization to 0.86.
  • perf-changelog.yaml: corresponding entry.

full-sweep-enabled: the image pin and parallelism arms both change, so cached results are not comparable.

中文说明

dsv4-fp4-mi355x-vllm-agentic-mtp 镜像更新为 vllm/vllm-openai-rocm:nightly-f8d03e77416bf90c49acbe50e233275722f02c4b,并补齐并发曲线中 DP-attention 的一半。

变更:更新所钉镜像;dp-attn 组合由单点扩展为 32/48/64/96;DP-attention 下 --max-num-seqs 收紧为 CONC(该上限按 scheduler 生效),并设置 --max-num-batched-tokens 8192--prefill-schedule-interval 8--long-prefill-token-threshold 16384;导出 VLLM_ROCM_USE_AITER_FUSION_SHARED_EXPERTS=1--gpu-memory-utilization 提高到 0.86。

申请 full-sweep-enabled:镜像 pin 与并行组合均变化,旧结果不可比。

@github-actions

Copy link
Copy Markdown
Contributor

Thanks for the contribution! Please reach out to respective companies' CODEOWNER to fill in the latest PR_REVIEW_CHECKLIST.md before pinging core maintainer on Slack for review. In order for the signoff PR check bot to trigger, you must follow the PR_REVIEW_CHECKLIST.md template correctly, including the phrase As a PR reviewer and CODEOWNER, I have reviewed this and have.

For PR verification, add the full-sweep-fail-fast label (strongly recommended) to this PR — the benchmark sweep only runs on labeled PRs. Use full-sweep-enabled only if you need matrix jobs to keep running past a failure.

PR authors are responsible for ensuring that after merging, all GitHub Action jobs fully pass. A lot of the time, failures are just flakes and simply re-running the failed jobs will fix it. See GitHub's docs on re-running failed jobs


感谢你的贡献!请联系相应公司的 CODEOWNER 填写最新的 PR_REVIEW_CHECKLIST.md,然后再在 Slack 上联系核心维护者进行审阅。为了触发 signoff PR 检查机器人,你必须正确遵循 PR_REVIEW_CHECKLIST.md 模板,包括保留英文语句 As a PR reviewer and CODEOWNER, I have reviewed this and have

如需进行 PR 验证,请为此 PR 添加 full-sweep-fail-fast 标签(强烈推荐)— 基准测试 sweep 仅在带有标签的 PR 上运行。仅当需要矩阵任务在失败后继续运行时才使用 full-sweep-enabled

PR 作者有责任确保合并后所有 GitHub Action 任务完全通过。 很多时候失败只是偶发抖动(flake),重新运行失败的任务即可解决。参见 GitHub 关于重新运行失败任务的文档

@jiacao-amd
jiacao-amd force-pushed the jiacao/dsv4-agentic-mtp-0809-nopatch branch from 9702fd6 to b816427 Compare August 13, 2026 06:30
@jiacao-amd jiacao-amd changed the title perf(dsv4-fp4-mi355x-vllm-agentic-mtp): repin to the 08-09 nightly and complete the DP-attention curve, no container patching / 重新钉到 08-09 nightly 并补齐 DP-attention 曲线,不打容器补丁 perf(dsv4-fp4-mi355x-vllm-agentic-mtp): repin to the 08-09 nightly and complete the DP-attention curve / 重新钉到 08-09 nightly 并补齐 DP-attention 曲线 Aug 13, 2026
@jiacao-amd jiacao-amd changed the title perf(dsv4-fp4-mi355x-vllm-agentic-mtp): repin to the 08-09 nightly and complete the DP-attention curve / 重新钉到 08-09 nightly 并补齐 DP-attention 曲线 perf(dsv4-fp4-mi355x-vllm-agentic-mtp): repin to the 08-09 nightly / 重新钉到 08-09 nightly Aug 13, 2026
…d complete the DP-attention curve

Repin to the 08-09 nightly (f8d03e77) so the config can start at all: the
previously pinned tag no longer serves this recipe, and the 08-12 nightly
(3ee2df30) memory-faults during the profile run.

Two arms: pure TP8 through its measured knee at 48, and DP-attention with
the experts left TP-sharded (ep 1) extended from a single conc-64 point to
32/48/64/96. No EP8 arm -- EP8 only pays off with the MegaMoE backend, which
needs mori.ir.flydsl, absent from this image.

Recipe side, all DP-attention-conditional: cap --max-num-seqs at CONC rather
than 2*CONC (the limit is per scheduler and DP-attention runs one per rank),
set --max-num-batched-tokens 8192 with --prefill-schedule-interval 8 and
--long-prefill-token-threshold 16384, and raise --gpu-memory-utilization
from 0.8 to 0.86.

重新钉到 08-09 nightly(f8d03e77),配置才能起得来:原先钉的 tag 已经跑不动这个
recipe,而 08-12 nightly(3ee2df30)在 profile run 阶段会 memory fault。

两条 arm:纯 TP8 跑到实测拐点 48,以及专家仍按 TP 切分(ep 1)的 DP-attention
arm,从原来单点 conc 64 扩展到 32/48/64/96。不加 EP8 arm —— EP8 只有配
MegaMoE 后端才划算,而它需要 mori.ir.flydsl,该镜像里没有。

recipe 侧改动均只在 DP-attention 下生效:--max-num-seqs 从 2*CONC 收到 CONC
(该上限是每个 scheduler 生效的,而 DP-attention 每个 rank 一个 scheduler),
设置 --max-num-batched-tokens 8192 配合 --prefill-schedule-interval 8 与
--long-prefill-token-threshold 16384,并把 --gpu-memory-utilization 从 0.8
提到 0.86。
@jiacao-amd
jiacao-amd force-pushed the jiacao/dsv4-agentic-mtp-0809-nopatch branch from b816427 to 1bbc5c4 Compare August 13, 2026 06:34
Jiahui Cao and others added 2 commits August 13, 2026 06:46
DSv4-Pro is a mixed checkpoint: MXFP4 routed experts with an FP8 shared
expert. vllm/models/deepseek_v4/amd/model.py gates the fused shared-expert
path on VLLM_ROCM_USE_AITER_FUSION_SHARED_EXPERTS, which defaults to False,
so the checked-in recipe was not running the configuration the validated
manual runs used. The aiter side (aiter/fused_moe_dp_shared_expert.py) is
present on the pinned base.

The flag is mutually exclusive with expert parallelism --
_fuse_shared_experts_enabled() returns False when enable_expert_parallel is
set -- which is consistent with both arms here running ep 1.

DSv4-Pro 是混合精度检查点:routed experts 为 MXFP4,shared expert 为 FP8。
vllm/models/deepseek_v4/amd/model.py 通过 VLLM_ROCM_USE_AITER_FUSION_SHARED_EXPERTS
控制 fused shared-expert 路径,该开关默认为 False,因此签入的 recipe 与已验证的
手工运行并非同一配置。aiter 侧(aiter/fused_moe_dp_shared_expert.py)在所钉基座中存在。

该开关与专家并行互斥 —— enable_expert_parallel 开启时
_fuse_shared_experts_enabled() 返回 False —— 这与本 PR 两条 arm 均为 ep 1 一致。
The gpu-memory-utilization bullet cited 138.85 GiB per rank, which was
measured on a different build than the pinned nightly; the figure for this
topology on a pre-#51473 base is 160.66 GiB with 34.17 GiB of KV left at
0.86. The max-num-batched-tokens comparison was taken on the expert-parallel
MegaMoE topology, not on the dp-attn arm, so it motivates the value rather
than establishing it. Also correct the dp-attn description: dp-attn true
maps to --tensor-parallel-size 1 --data-parallel-size 8, so the weights are
replicated per rank rather than TP-sharded.

将 gmu 与 MNBT 的依据回溯到其真实来源的运行。138.85 GiB 来自另一构建;
本拓扑在 pre-#51473 基座上的实测为每 rank 160.66 GiB、0.86 下仅剩 34.17 GiB KV。
MNBT 对比取自专家并行 MegaMoE 拓扑而非本 arm,只作选值依据。
同时更正 dp-attn 描述:其对应 TP=1 + DP=8,权重按 rank 复制而非 TP 切分。

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
@jiacao-amd
jiacao-amd marked this pull request as ready for review August 13, 2026 07:08
@jiacao-amd
jiacao-amd requested a review from a team August 13, 2026 07:08
@claude

claude Bot commented Aug 13, 2026

Copy link
Copy Markdown
Contributor

Claude finished @jiacao-amd's task in 3m 27s —— View job


PR Review

  • Gather context (diff against origin/main)
  • Review benchmark script changes
  • Review config + perf-changelog changes
  • Verify claims against repo state
  • Post review

LGTM - no blocking issues found

Checks performed:

  • configs/amd-master.yaml modified with a matching perf-changelog.yaml entry, appended at the end of the file with the PR link backfilled ✓
  • New image vllm/vllm-openai-rocm:nightly-f8d03e77… is a public Docker Hub reference ✓
  • Expert parallelism stays conditional on EP_SIZE (EP_ARGS pattern); the new VLLM_ROCM_USE_AITER_FUSION_SHARED_EXPERTS=1 is gated inside vLLM against EP, consistent with both arms running ep 1
  • DP_SCHED_ARGS gating, the MAX_NUM_SEQS override, and the config's dp-attn conc-list/router version are internally consistent with the script's DP-attention path (tp 1 / dp 8 + vllm-router 0.1.14) ✓
  • --prefill-schedule-interval / --long-prefill-token-threshold / --max-num-batched-tokens under DP-attention mirror the established pattern in the dsv4 b200/b300 agentic siblings ✓
  • Server launch command is array-formatted one argument per line ✓

Note: the inferencemax-repos MCP server was not available in this run, so I could not verify against vLLM source that the ROCm 08-09 nightly accepts --prefill-schedule-interval; the sibling dsv4 agentic recipes already use it and the PR states the DP-attention concurrency-64 point was measured on this base with these flags, so risk is low and the labeled sweep will confirm.

@jiacao-amd jiacao-amd changed the title perf(dsv4-fp4-mi355x-vllm-agentic-mtp): repin to the 08-09 nightly / 重新钉到 08-09 nightly perf(dsv4-fp4-mi355x-vllm-agentic-mtp): update the vLLM ROCm image and extend the DP-attention concurrency curve / 更新 vLLM ROCm 镜像并扩展 DP-attention 并发曲线 Aug 13, 2026
@jiacao-amd jiacao-amd changed the title perf(dsv4-fp4-mi355x-vllm-agentic-mtp): update the vLLM ROCm image and extend the DP-attention concurrency curve / 更新 vLLM ROCm 镜像并扩展 DP-attention 并发曲线 perf(dsv4-fp4-mi355x-vllm-agentic-mtp): update image and extend the DP-attention concurrency curve / 更新镜像并扩展 DP-attention 并发曲线 Aug 13, 2026

@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.

LGTM — the one inline finding is a nit (an inert flag value, not a functional break), and the rest of the repin/config changes are well-reasoned and self-contained.

Extended reasoning...

Overview

This PR repins the dsv4-fp4-mi355x-vllm-agentic-mtp recipe to a new ROCm nightly and extends the DP-attention concurrency ladder. Changes are confined to a benchmark launch script, the corresponding amd-master.yaml search-space entry, and an append-only perf-changelog.yaml entry — no production serving code, auth, or shared infrastructure is touched.

Security risks

None. This is benchmark/tuning configuration for an internal sweep harness; it does not touch request handling, credentials, or externally reachable code paths.

Level of scrutiny

Low-to-moderate is appropriate here: it's a data/config change (image pin bump, concurrency list, and a handful of vLLM CLI flags gated behind DP_ATTENTION=true) rather than a logic change to shared code. The one inline finding (a --long-prefill-token-threshold value that can never bind under the accompanying --max-num-batched-tokens budget) is flagged as a Nit by the bug hunter — it doesn't crash or break the run, it just leaves a piece of the stated 'chunk long prefills' rationale as dead configuration. The sweep itself will still execute and produce valid throughput numbers for the arm.

Other factors

The PR description is thorough and grounds each flag change (max-num-seqs capping, gpu-memory-utilization bump, aiter fused shared-expert flag) in specific measurements or code references. The PR is still in draft pending sweep results per its own description, and full-sweep-enabled is applied appropriately given the image/topology changes. No unresolved reviewer threads exist in the timeline.

Comment on lines +374 to +380
DP_SCHED_ARGS=()
if [ "$DP_ATTENTION" = "true" ]; then
DP_SCHED_ARGS=(
--prefill-schedule-interval 8
--max-num-batched-tokens 8192
--long-prefill-token-threshold 16384
)

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.

🟡 With DP_ATTENTION=true, --long-prefill-token-threshold 16384 is set larger than --max-num-batched-tokens 8192, making it an inert no-op: vLLM's V1 scheduler caps a request's per-step token count at the threshold before clamping to the token budget, so a threshold above the budget can never bind. This defeats the stated purpose ('long prefills are chunked rather than starving decode'); the sibling recipe dsv4_fp4_b300_vllm_mtp.sh uses the correct inverse relationship (threshold 512 << budget), and this value should likely be similarly small (e.g. 512).

Extended reasoning...

The bug. benchmarks/single_node/agentic/dsv4_fp4_mi355x_vllm_mtp.sh:374-380 sets, under DP_ATTENTION=true:

--max-num-batched-tokens 8192
--long-prefill-token-threshold 16384

In vLLM's V1 scheduler (vllm/v1/core/sched/scheduler.py), long_prefill_token_threshold is applied as a per-step cap on a request's num_new_tokens, and that cap is applied before the min() with token_budget (which derives from --max-num-batched-tokens). Concretely, both the running-request loop and the waiting-request (prefill) loop do:

if 0 < self.scheduler_config.long_prefill_token_threshold < num_new_tokens:
    num_new_tokens = self.scheduler_config.long_prefill_token_threshold
num_new_tokens = min(num_new_tokens, token_budget)

Since min(min(N, 16384), 8192) == min(N, 8192) for any N, the 16384 clamp can never be the binding constraint when the budget is only 8192 — it is a pure no-op. This directly contradicts the PR description's stated rationale for adding the flag: "so long prefills are chunked rather than starving decode." As written, a single long prefill still consumes the full 8192-token budget in one scheduler step, which is exactly the decode-starvation scenario the flag is meant to prevent.

Proof by walkthrough. Take a request with a 40,000-token prompt.

  1. num_new_tokens is initially computed as the remaining prompt tokens to process this step, e.g. 40000 (before any budget/threshold clamp).
  2. Threshold check: 0 < 16384 < 40000 is true, so num_new_tokens is set to 16384.
  3. Budget clamp: num_new_tokens = min(16384, 8192) = 8192.
  4. The final scheduled chunk size is 8192 — identical to what would have been scheduled with no threshold set at all (long_prefill_token_threshold=0 disables the cap entirely, per its own docstring). The 16384 value never had any effect on the outcome for any prompt length, because step 3 always overrides step 2 whenever threshold > budget.

Why this isn't caught elsewhere. I checked whether a second mechanism (e.g., classifying a request as "long" against its total prompt length for a concurrent-long-prefill limiter, as one reviewer speculated) exists in this vLLM version that might make the 16384 value meaningful independently of the per-step cap. It does not: grepping the scheduler and scheduler-config modules for long_prefill / max_long_partial_prefills turns up only the three call sites above, all of which use the threshold identically as a per-step num_new_tokens cap, not a request-classification threshold compared against num_prompt_tokens. The field's docstring ("a request is considered long if the prompt is longer than this number of tokens") is a legacy description of intent, but the actual gating logic operates purely on per-step token counts, so the threshold's real effect is exactly what the code does with it — cap the chunk, then get overridden by the smaller budget.

Impact. Nothing crashes and the arm still runs — --prefill-schedule-interval 8 provides separate prefill-scheduling cadence throttling, and the sweep measures the arm's throughput regardless of whether this particular flag does anything. But the flag is dead configuration: it does not chunk long prefills any more tightly than --max-num-batched-tokens already does on its own, so any decode-starvation behavior from long prefills under DP-attention is unmitigated by this addition, contrary to what the PR description claims it does.

Fix. Lower --long-prefill-token-threshold below --max-num-batched-tokens (8192), e.g. to 512, mirroring the working pattern in the sibling recipe benchmarks/single_node/agentic/dsv4_fp4_b300_vllm_mtp.sh (--long-prefill-token-threshold 512 alongside --max-num-batched-tokens 8192/16384), which is commented there as keeping "decode latency bounded under load."

@seungrokj seungrokj added AMD agentx AgentX benchmarks, recipes, and infrastructure labels Aug 13, 2026
@seungrokj seungrokj changed the title perf(dsv4-fp4-mi355x-vllm-agentic-mtp): update image and extend the DP-attention concurrency curve / 更新镜像并扩展 DP-attention 并发曲线 [AMD] [AgentX] dsv4-fp4-mi355x-vllm-agentic-mtp, update image and extend the DP-attention concurrency curve Aug 13, 2026
@github-actions

Copy link
Copy Markdown
Contributor

@seungrokj

Copy link
Copy Markdown
Collaborator

/reuse-sweep-run

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

Labels

agentx AgentX benchmarks, recipes, and infrastructure AMD full-sweep-enabled

Projects

Status: No status

Development

Successfully merging this pull request may close these issues.

2 participants