[AgentX]: Use burst phase starts by default / [AgentX]:默认使用阶段起始突发模式 - #2375
Conversation
Allow saturation recipes to request AIPerf burst phase starts without changing the default faithful replay behavior. Validate the environment value and cover enabled, disabled, and invalid command generation. 中文:允许饱和度测试配置按需启用 AIPerf 阶段起始突发,同时保持默认的忠实回放行为不变。新增环境变量校验,并覆盖启用、禁用和非法值的命令生成测试。
|
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 For PR verification, add the 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 模板,包括保留英文语句 如需进行 PR 验证,请为此 PR 添加 PR 作者有责任确保合并后所有 GitHub Action 任务完全通过。 很多时候失败只是偶发抖动(flake),重新运行失败的任务即可解决。参见 GitHub 关于重新运行失败任务的文档 |
Start selected AgentX trajectories together by default so configured concurrency is active within the benchmark window. Preserve faithful recorded phase-start spreading as an explicit AIPERF_BURST_PHASE_STARTS=0 override. 中文:默认同步启动选中的 AgentX 轨迹,使配置的并发度能在基准测试窗口内生效;同时保留 AIPERF_BURST_PHASE_STARTS=0,用于显式恢复按记录时间分散启动。
Update the AIPerf submodule to make burst phase starts the default and remove duplicate InferenceX wrapper plumbing and tests. 中文:更新 AIPerf 子模块,将阶段起始突发设为默认行为,并移除 InferenceX 中重复的封装逻辑和测试。
Point the AIPerf submodule at the cquil11/aiperf-agentx-v1.0 merge commit containing the phase-start default change. 中文:将 AIPerf 子模块更新到 cquil11/aiperf-agentx-v1.0 分支中包含阶段起始默认行为变更的合并提交。
|
Claude finished @cquil11's task in 2m 26s —— View job PR Review
LGTM - no blocking issues found. The diff is exactly the one-line
Note: I couldn't inspect the AIPerf commit contents directly (submodule not initialized in this environment and network access to the aiperf repo is restricted), so the behavioral review of the default change itself rests on the merged upstream review in SemiAnalysisAI/aiperf#22 and the reported validation (758 AIPerf tests, 224 matrix tests). |
There was a problem hiding this comment.
LGTM - this is a one-line submodule pointer bump (utils/aiperf to 208125ac) pulling in an already-merged, reviewed upstream change that flips burst_phase_starts to default True. The one finding is a doc-only nit (stale docstring text) inside the submodules own commit history with no functional impact.
Extended reasoning...
Overview
The entire InferenceX-side diff is a single line: the utils/aiperf submodule pointer moves from f5ae8134 to 208125ac, the merge commit for cquil11/aiperf-agentx-v1.0 (upstream PR SemiAnalysisAI/aiperf#22). There is no InferenceX wrapper code, config, or test file touched - the behavioral change (Agentic Replay warmup/profiling phase starts default to burst instead of spread) lives entirely inside the aiperf submodule.
Security risks
None. This is a benchmarking-tool timing/dispatch behavior change with no auth, crypto, injection, or data-exposure surface.
Level of scrutiny
Low-to-moderate is appropriate: the InferenceX-visible change is a mechanical submodule bump, so I read into the submodule itself to verify the underlying commit (fb39d0df) actually does what the PR description claims. I confirmed the config default flip in loadgen_config.py (False to True), the corresponding docstring update in docs/cli-options.md, and that the dispatch logic in agentic_replay.py (spread = not self._burst_phase_starts, and the burst/spread branches in _execute_warmup and _dispatch_snapshot_for_profiling) correctly implements the new default - no functional bug there. The behavior is escapable via burst_phase_starts: false for anyone who needs the old faithful-replay timing.
Other factors
The one flagged issue (stale spread-is-default wording left in two docstrings/comments in the same file, contradicting the now-accurate module-level docstring) is cosmetic, pre-existing in the upstream commit being pulled in, and does not affect runtime behavior - the actual branch conditions were updated correctly everywhere checked. It does not warrant blocking this bump; a follow-up doc fix in the upstream aiperf repo is sufficient. The PR description also documents concrete motivation (concurrency never reaching target under spread mode, evidenced by large recorded offsets at concurrency 32/256) and reports both AIPerf's and InferenceX's test suites passing.
| @@ -1 +1 @@ | |||
| Subproject commit f5ae8134f863993e412d350e406fbcacfe714a7a | |||
| Subproject commit 208125aca87a438e43e56517e8a3e5096f8c9281 | |||
There was a problem hiding this comment.
🟡 The aiperf submodule bump (fb39d0df) flips burst_phase_starts to default True and updates the module-level docstring in agentic_replay.py accordingly, but two other docstrings in the same file — _execute_warmup's "Dispatch timing" docstring (~line 496) and the inline comment in _dispatch_snapshot_for_profiling (~line 1499) — still describe spread as the default and burst as the opt-in flag, now contradicting actual behavior. This is a pre-existing issue in the upstream aiperf commit being pulled in, doc-only with no functional impact, and would need a follow-up fix + re-bump in the aiperf repo.
Extended reasoning...
What the bug is: Commit fb39d0df ("refactor(agentic): burst phase starts by default") in the bumped utils/aiperf submodule flips burst_phase_starts from False to True (see loadgen_config.py:278) and correctly updates the module-level docstring and the __init__ comment in src/aiperf/timing/strategies/agentic_replay.py to describe burst as the new default. However, two other docstrings in the same file that describe the same flag were left untouched and now say the opposite of what's true.
Where it manifests:
_execute_warmup's "Dispatch timing" docstring (~line 496-507) still reads:Default (spread): aligned GLOBALLY...and frames--burst-phase-startsas the override that changes behavior away from the default.- The inline comment inside
_dispatch_snapshot_for_profiling(~line 1499-1501) still reads:Spread (default): t0 = 0 ... Burst (--burst-phase-starts): t0 = the lane's min offset.
Both explicitly label "spread" as the default, which was true before this commit but is now false — the default is burst.
Why the existing update missed these: The diff for fb39d0df only touched the module docstring (lines ~20-40) and the __init__ comment (lines ~215-221), which are the two most visible places describing the flag. It missed that the same "default vs. override" framing was duplicated verbatim in two method-level docstrings further down in the file, so those got left behind when the semantics flipped.
Impact: This is purely a documentation/comment inconsistency — the actual dispatch logic in both methods is correct and unaffected (the code paths still correctly branch on self._burst_phase_starts). No runtime behavior changes. The only impact is that a future reader of _execute_warmup or _dispatch_snapshot_for_profiling in isolation would be misled about which behavior is the current default, since these method-level docs now contradict the accurate module-level docstring in the same file.
Proof (step-by-step):
- Before
fb39d0df:burst_phase_startsdefaulted toFalse(spread). Module docstring,__init__comment,_execute_warmupdocstring, and_dispatch_snapshot_for_profilingcomment all consistently said "spread is default." fb39d0dfchangesloadgen_config.py's default toTrue(burst) and updates the module docstring (~line 24: "By default the priming requests BURST together...") and__init__comment (~lines 215-216: "Real loadgen configs default to burst...").- The commit's diff (visible in the verifier logs) shows no changes to the
Default (spread):string in_execute_warmupor theSpread (default):string in_dispatch_snapshot_for_profiling. - Reading those two methods today:
_execute_warmupsays spread is default while the module docstring 60 lines above it says burst is default — a direct, verifiable contradiction within the same file.
How to fix: In the upstream aiperf repo, swap the "default"/"override" labeling in both the _execute_warmup docstring and the _dispatch_snapshot_for_profiling inline comment to match the new burst-by-default semantics (mirroring the wording already used in the module docstring), then re-bump the utils/aiperf submodule pointer in InferenceX. This doesn't need to block the current PR since it's doc-only and pre-existing in the commit being pulled in — a quick follow-up is sufficient.
Summary
utils/aiperfsubmodule fromf5ae8134to208125ac, the merge commit oncquil11/aiperf-agentx-v1.0.burst_phase_starts: falserestores spread phase starts.Merged AIPerf change: SemiAnalysisAI/aiperf#22
Discovered while bringing up Kimi K3 GB200 AgentX in #2354. Recorded initial offsets reached 56,048.7 seconds at concurrency 32 and 252,825.1 seconds at concurrency 256, so spread phase starts could prevent the requested concurrency from becoming active during the run.
Validation
中文说明
utils/aiperf子模块从f5ae8134更新到cquil11/aiperf-agentx-v1.0分支上的合并提交208125ac。burst_phase_starts: false可恢复分散式阶段启动。已合并的 AIPerf 变更:SemiAnalysisAI/aiperf#22
该问题是在 #2354 的 Kimi K3 GB200 AgentX 启动调试中发现的。并发度为 32 和 256 时,记录的初始偏移分别达到 56,048.7 秒和 252,825.1 秒,分散式阶段启动可能导致目标并发度在测试期间始终无法生效。
验证