Skip to content

[AMD][AgentX] Add MI300X MiniMax-M3 EAGLE3 MXFP8 - #2580

Open
cquil11 wants to merge 4 commits into
mainfrom
agent/mi300x-minimax-m3-eagle3-fp8
Open

[AMD][AgentX] Add MI300X MiniMax-M3 EAGLE3 MXFP8#2580
cquil11 wants to merge 4 commits into
mainfrom
agent/mi300x-minimax-m3-eagle3-fp8

Conversation

@cquil11

@cquil11 cquil11 commented Aug 12, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • Add MiniMax-M3 MXFP8 AgentX on MI300X with vLLM v0.27.1, EAGLE3-GQA K=3, and the committed synthetic acceptance length 2.78.
  • Use the measured resident TP8 curve at c2/c4/c6/c8/c10 and one validated LMCache MP DRAM-offload point at c16.
  • Export exactly one logical AIPerf metrics endpoint, http://localhost:$PORT/metrics, with required vllm: metrics.

Discovery evidence

  • Complete 38-arm fast run: https://github.com/SemiAnalysisAI/InferenceX/actions/runs/31621138962 (23 green, 15 failed, no cancellations).
  • TP4 and TP4/EP4 are excluded because every arm deterministically failed model residency during MXFP8 dequantization.
  • Resident TP8 throughput peaked at c10; c12+ crossed the memory/scheduling cliff. TP8/EP8 did not beat resident TP8.
  • LMCache MP c16 was functional and improved on resident c16, so it is retained as the high-concurrency offload point.
  • TP8 c1 is excluded after three identical normal-duration fixed-seed runs each completed 147 valid requests with zero errors but left the same final trajectory open, making the point non-validatable under the strict final-window coverage check.

Validation

  • bash -n benchmarks/single_node/agentic/minimaxm3_fp8_mi300x_mtp.sh
  • AMD master and performance changelog YAML parse successfully.
  • Official matrix emits six throughput jobs: five resident TP8 points plus LMCache MP c16.
  • utils/matrix_logic/test_generate_sweep_configs.py: 105 passed.

@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 关于重新运行失败任务的文档

cquil11 added a commit that referenced this pull request Aug 12, 2026
Record PR #2580 in the appended performance changelog entry.

在新增的性能变更日志条目中记录 PR #2580
@cquil11 cquil11 added AMD agentx AgentX benchmarks, recipes, and infrastructure agentx-fast Run AgentX throughput with 1 warmup request per lane and a 20-minute profile; not reusable labels Aug 12, 2026
@cquil11 cquil11 changed the title [AMD][AgentX] Add MI300X MiniMax-M3 EAGLE3 MXFP8 discovery / 添加 MI300X MiniMax-M3 EAGLE3 MXFP8 发现扫描 [AMD][AgentX] Add MI300X MiniMax-M3 EAGLE3 MXFP8 discovery Aug 12, 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.

Approving — the two flagged issues are both nits (a duplicated LMCache spin-up block missing a pre-flight check, and a required-but-unconsumed DP_ATTENTION var) that don't affect correctness of this PR's actual search space; see inline comments for details.

Extended reasoning...

Overview

This PR adds a new AgentX benchmark recipe: a MiniMax-M3 MXFP8 EAGLE3-MTP discovery sweep on MI300X via vLLM v0.27.1. Changes are a new shell launch script (minimaxm3_fp8_mi300x_mtp.sh), a new amd-master.yaml search-space entry, and a perf-changelog.yaml record. The new script closely mirrors sibling recipes already in the repo (minimaxm3_fp8_mi300x.sh, minimaxm3_fp4_mi355x_mtp.sh) in structure: env var checks, model download, vLLM serve command construction, optional LMCache MP KV-offload spin-up, and eval/replay dispatch.

Security risks

None identified. This is CI benchmark infrastructure — env vars come from the sweep-config generator (not user-controlled input), there's no auth/crypto surface, and the LMCache/vLLM invocations use fixed, hardcoded flags rather than interpolating untrusted data into anything eval'd or interpreted unsafely.

Level of scrutiny

Low-to-moderate. This is a new discovery recipe following an extremely well-established pattern in this repo (many nearly-identical sibling scripts/configs exist), it doesn't touch shared library code (benchmark_lib.sh is unchanged), and it only affects a single isolated benchmark matrix entry — blast radius of any latent issue is a single job's CI results, not shared behavior.

Other factors

Both bug-hunter findings are explicitly scoped as Nits: one is a code-duplication/pre-flight-check quality gap in the LMCache branch (only exercised by one isolated gate arm), and the other is a required-but-unconsumed DP_ATTENTION env var that is harmless under the current search space (no dp-attn: true row exists in this recipe) and mirrors an existing pattern already present in other sibling scripts (glm5.2_fp8_mi325x_mtp.sh, minimaxm3_fp4_mi355x_mtp.sh). Neither affects the correctness of what this PR actually ships. The PR's own validation section shows bash -n, YAML parsing, and the sweep-config test suite (105 passed) all green.

Comment on lines +62 to +80

OFFLOAD_ARGS=()
case "$KV_OFFLOAD_BACKEND" in
"")
require_agentic_kv_offload_none
;;
lmcache)
require_agentic_kv_offload_backend lmcache
LMCACHE_VERSION="0.5.3"
LMCACHE_ROCM_INDEX="https://github.com/LMCache/LMCache/releases/expanded_assets/v${LMCACHE_VERSION}-rocm"
agentic_pip_install --quiet --no-cache-dir --no-deps \
"sortedcontainers==2.4.0" \
"opentelemetry-exporter-prometheus==0.61b0" \
"cupy-rocm-7-0==14.1.1" \
"lmcache==${LMCACHE_VERSION}" --find-links "$LMCACHE_ROCM_INDEX"
python3 -c \
"import cupy; import lmcache.integration.vllm.lmcache_mp_connector; import opentelemetry.exporter.prometheus" \
>/dev/null

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.

🟡 This LMCache MP shard spin-up block (lines 62-128) is a near-verbatim duplicate (~55 lines) of the one in minimaxm3_fp4_mi355x_mtp.sh, and unlike that sibling it drops the pre-flight check that verifies LMCACHE_L1_SIZE_GB doesn't exceed 90% of free /dev/shm before launching. Worth extracting a shared start_lmcache_mp_shards helper into benchmark_lib.sh (removing the duplication) and restoring the /dev/shm guard so an oversized DRAM budget fails with a clear error instead of an opaque lmcache OOM/crash.

Extended reasoning...

What's duplicated: Lines 62-128 of minimaxm3_fp8_mi300x_mtp.sh reimplement the per-TP-rank LMCache MP server spin-up loop that already exists in benchmarks/single_node/agentic/minimaxm3_fp4_mi355x_mtp.sh (its equivalent block runs roughly lines 79-165). Both use the identical port scheme (shard_port=5555+shard, shard_http_port=8080+shard), the identical lmcache CLI flag set (--l1-init-size-gb 10 --l1-read-ttl-seconds 7200 --chunk-size 256 --max-workers 2 --eviction-policy LRU --supported-transfer-mode lmcache_driven), the same append_command/background-launch pattern, and the same wait_for_ready healthcheck loop plus the same LMCacheMPConnector OFFLOAD_ARGS kv-transfer-config construction. benchmark_lib.sh already centralizes shared agentic helpers (require_agentic_kv_offload_backend, wait_for_ready, stop_background_process_tree, append_command), so this block is a natural candidate for a start_lmcache_mp_shards helper that both scripts could call, removing roughly 55 duplicated lines.\n\nWhat's missing: the mi355x sibling has a pre-flight guard (around its lines 104-111) that computes free /dev/shm via df -BG /dev/shm and exits with a clear error if LMCACHE_L1_SIZE_GB would exceed 90% of that free space. The mi300x copy in this PR omits that check entirely — it goes straight from LMCACHE_L1_SHARD_GB=$((TOTAL_CPU_DRAM_GB / TP)) to only a -lt 1 floor check (line ~68-71 here). Since LMCache MP's L1 tier is backed by shared memory, a TOTAL_CPU_DRAM_GB/TP budget that's too large for the runner's actual /dev/shm capacity won't be caught up front; it will instead surface later as an opaque lmcache server crash or OOM in lmcache_server_*.log, which is much harder to diagnose than the sibling script's explicit pre-flight error.\n\nConcrete walk-through: suppose the mi300x runner has 512GB of /dev/shm" but the job is launched with TOTAL_CPU_DRAM_GB=600andTP=4(e.g. a copy-pasted or misconfigureddram-utilization/config value). LMCACHE_L1_SHARD_GB computes to 150GB per shard × 4 shards = 600GB total requested, exceeding the 512GB actually available. The mi355x sibling's check would catch this immediately (600 > 512 * 0.9 = 460.8) and exit with "Error: LMCache L1 size exceeds ... /dev/shm" before any process starts. In this PR's mi300x script, the -lt 1check passes fine (150 ≥ 1), so all fourlmcache serverbackground processes launch, each trying to mmap a 150GB region in the same shared/dev/shm; they will either fail to allocate, get OOM-killed, or degrade in ways that only show up in the per-shard logs after the fact, all while the outer wait_for_ready loop times out after up to 600 seconds — a much slower and more confusing failure than the sibling's instant, actionable error.\n\n**Why this matters but isn't blocking:** this LMCache configuration is exercised by exactly one isolated gate arm (tp: 8, conc-list: [16]) in the new minimaxm3-fp8-mi300x-vllm-agentic-mtpmatrix entry, so the blast radius if it does misconfigure is a single functional-gate job failing loudly (if diagnosed) rather than a broader correctness or data-loss issue. It's a code-quality / parity gap relative to the sibling recipe, not a bug that breaks the documented behavior of this PR.\n\n**Fix:** extract the LMCache MP spin-up loop (including the/dev/shmpre-flight check) from the mi355x script into a sharedstart_lmcache_mp_shardsfunction inbenchmark_lib.sh, and have both minimaxm3_fp8_mi300x_mtp.shandminimaxm3_fp4_mi355x_mtp.sh` call it. This removes the ~55-line duplication and restores the missing capacity check in one change.


export EVAL_FRAMEWORK="lm-eval"

check_env_vars MODEL TP CONC KV_OFFLOADING TOTAL_CPU_DRAM_GB RESULT_DIR DURATION EP_SIZE DP_ATTENTION PORT EVAL_ONLY

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.

🟡 The new minimaxm3_fp8_mi300x_mtp.sh requires DP_ATTENTION via check_env_vars (line 11) but never branches on it — PARALLEL_ARGS only checks EP_SIZE. It's harmless today since every row in minimaxm3-fp8-mi300x-vllm-agentic-mtp defaults dp-attn to false, but sibling recipes with the same required var (e.g. minimaxm3_fp8_mi300x.sh, dsv4_fp4_mi355x_vllm_mtp.sh) do consume it to build DP-attention flags, so if a future dp-attn: true row is added here (as already exists for the sibling mi325x recipe), the server would silently launch plain TP/EP while the sweep still labels it DEP.

Extended reasoning...

The bug: benchmarks/single_node/agentic/minimaxm3_fp8_mi300x_mtp.sh:11 lists DP_ATTENTION in its check_env_vars call, asserting the script depends on that variable. But grepping the rest of the script shows it is never referenced again — PARALLEL_ARGS (around the EP_SIZE-gated --enable-expert-parallel block) only branches on EP_SIZE. There is no analogous branch that would add --data-parallel-size, bump the port, or start a router when DP_ATTENTION=true.

Contrast with siblings that do consume it: minimaxm3_fp8_mi300x.sh (lines 150/160/188), minimaxm3_fp8_mi325x.sh (150/165/198), and dsv4_fp4_mi355x_vllm_mtp.sh (70/365) all require the same variable and use it to switch between plain TP/EP and DP-attention serving (different parallel args, a different port, and launching vllm-router). Those scripts show what 'consuming' DP_ATTENTION is supposed to look like in this codebase, and the new MTP script has the requirement without the corresponding behavior.

Why this doesn't currently break anything: every search-space row under minimaxm3-fp8-mi300x-vllm-agentic-mtp in configs/amd-master.yaml omits dp-attn, which generate_sweep_configs.py defaults to false. With DP_ATTENTION=false, the correct behavior (plain TP/EP) is exactly what the script does anyway, so no current run is mislabeled.

Why it's still worth flagging (as a nit, not a blocker): it's a latent footgun rather than an active bug. dp-attn: true rows already exist for sibling recipes in the very same amd-master.yaml file (e.g. minimaxm3-fp8-mi325x-vllm-agentic, dsv4-fp4-mi355x-vllm-agentic-mtp). If a future row adds dp-attn: true to this recipe, the sweep would set DP_ATTENTION=true and record the point as a DEP config, but the script would silently serve plain TP/EP — corrupting the benchmark's performance-curve labeling with no error surfaced anywhere in the pipeline.

Step-by-step proof: (1) A maintainer adds { tp: 8, ep: 8, dp-attn: true, ... } to minimaxm3-fp8-mi300x-vllm-agentic-mtp in amd-master.yaml, mirroring the pattern already used for minimaxm3-fp8-mi325x-vllm-agentic. (2) generate_sweep_configs.py emits a job with DP_ATTENTION=true. (3) check_env_vars passes since the variable is set. (4) The script builds PARALLEL_ARGS=(--tensor-parallel-size "") plus --enable-expert-parallel from EP_SIZE alone — DP_ATTENTION is never read, so no --data-parallel-size flag is added and no router is started. (5) The server runs as plain TEP8, but the result is recorded and labeled as a DEP8 data point in the benchmark output, silently corrupting the recorded performance curve.

On the refutation: one verifier correctly points out that this exact required-but-unconsumed pattern already exists in glm5.2_fp8_mi325x_mtp.sh:11 and minimaxm3_fp4_mi355x_mtp.sh:16 (confirmed by inspection — both require DP_ATTENTION via check_env_vars and never branch on it, the latter only echoing it for logging). So this specific script isn't introducing a wholly novel anti-pattern into the repo, and removing DP_ATTENTION from the required-var list would arguably regress the intended uniform env-contract assertion across the agentic family. That's a fair point, and it's why this should stay a nit rather than escalate to normal — but it doesn't fully neutralize the finding: several other siblings in the same model family (minimaxm3_fp8_mi300x.sh, minimaxm3_fp8_mi325x.sh) do wire DP_ATTENTION into real behavior, and this recipe's own amd-master.yaml neighbors already ship dp-attn: true rows for other configs. The inconsistency is real even if the specific failure mode is speculative and not triggered by this PR's search space.

Suggested fix: either wire DP_ATTENTION into PARALLEL_ARGS (mirroring minimaxm3_fp8_mi300x.sh) so a future dp-attn: true row behaves correctly, or drop it from check_env_vars if DP-attention is intentionally out of scope for this MTP recipe. Either fix removes the silent-mislabeling risk.

@github-actions

Copy link
Copy Markdown
Contributor

@cquil11 cquil11 removed the agentx-fast Run AgentX throughput with 1 warmup request per lane and a 20-minute profile; not reusable label Aug 13, 2026
cquil11 added a commit that referenced this pull request Aug 13, 2026
Record PR #2580 in the appended performance changelog entry.

在新增的性能变更日志条目中记录 PR #2580
@cquil11
cquil11 force-pushed the agent/mi300x-minimax-m3-eagle3-fp8 branch from 77b9f55 to d2ff4b6 Compare August 13, 2026 01:23
@cquil11 cquil11 changed the title [AMD][AgentX] Add MI300X MiniMax-M3 EAGLE3 MXFP8 discovery [AMD][AgentX] Add MI300X MiniMax-M3 EAGLE3 MXFP8 Aug 13, 2026
@github-actions

Copy link
Copy Markdown
Contributor

2 similar comments
@github-actions

Copy link
Copy Markdown
Contributor

@github-actions

Copy link
Copy Markdown
Contributor

Add a broad TP4/TP8 resident discovery grid plus an isolated LMCache MP offload gate for MiniMax-M3 MXFP8 on MI300X. Use vLLM EAGLE3-GQA with the committed golden acceptance length and require the single aggregate vLLM metrics endpoint.

新增 MI300X MiniMax-M3 MXFP8 的 TP4/TP8 常驻发现矩阵及独立 LMCache MP 卸载验证点。使用 vLLM EAGLE3-GQA 与已提交的黄金接受长度,并要求采集单一聚合 vLLM 指标端点。
Record PR #2580 in the appended performance changelog entry.

在新增的性能变更日志条目中记录 PR #2580
@cquil11
cquil11 force-pushed the agent/mi300x-minimax-m3-eagle3-fp8 branch from d2ff4b6 to 074ec53 Compare August 13, 2026 06:05
@github-actions

Copy link
Copy Markdown
Contributor

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.

1 participant