fix(agentx): align profiling with measured workload phase - #1386
Merged
Conversation
jiaqiang-dot-liu
requested review from
a team and
devalshahamd
as code owners
September 2, 2026 11:35
| fields = stat.rsplit(")", 1) | ||
| if len(fields) == 2 and fields[1].strip().split(maxsplit=1)[0] == "Z": | ||
| return False | ||
| except (OSError, IndexError): |
| fields = stat.rsplit(")", 1) | ||
| if len(fields) == 2 and fields[1].strip().split(maxsplit=1)[0] == "Z": | ||
| return False | ||
| except (OSError, IndexError): |
Hyperloom Forge E2E — ❌ Timeout
|
CI E2E report — ❌ Timeout
|
Gate bounded trace capture on AIPerf phase progress, preserve capture failures independently, and keep single-rank analysis off merged traces. Co-authored-by: Cursor <cursoragent@cursor.com>
Guarantee profiler shutdown on gate errors, remove unreliable request-coverage stopping, and tighten rank, timeout, status, and preflight handling from review feedback. Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Reject missing capture state, preserve actionable flush reasons, complete vLLM rank matching, and avoid deterministic profile retries. Co-authored-by: Cursor <cursoragent@cursor.com>
Let the outer profile deadline bound large-model warmup and resolve single-trace compatibility without relying solely on process TP state. Co-authored-by: Cursor <cursoragent@cursor.com>
jiaqiang-dot-liu
force-pushed
the
fix/agentx-phase-aligned-profiling
branch
from
September 3, 2026 01:36
76ea161 to
6ed8a39
Compare
Rename internal AIPerf progress variables so Gitleaks does not interpret a failure reason as an API credential. Co-authored-by: Cursor <cursoragent@cursor.com>
Parse vLLM global rank before node-local TP rank while preserving SGLang and ATOM naming fallbacks. Co-authored-by: Cursor <cursoragent@cursor.com>
Allow unranked compatibility traces only when the run is single-rank or TP is unknown, never when a multi-rank run is missing rank zero. Co-authored-by: Cursor <cursoragent@cursor.com>
Keep bypass analysis on a single rank, preserve measurement outcomes independently, surface capture API degradation, and fail unsupported multi-node profiling explicitly. Co-authored-by: Cursor <cursoragent@cursor.com>
Create trace directories before writing fixtures and update TP-tagged provenance expectations. Co-authored-by: Cursor <cursoragent@cursor.com>
Allocate a per-invocation capture ID and status path before Magpie starts, validate that contract on return, and publish a trace manifest without relying on RESULT_DIR rewriting. Co-authored-by: Cursor <cursoragent@cursor.com>
Pass the session-level AgentX decision through benchmark materialization and preserve it when grid variants rebuild configuration without the ambient env flag. Co-authored-by: Cursor <cursoragent@cursor.com>
Only classify a missing capture sidecar after a successful measurement, leaving server, CUDA graph, and memory failures intact for roofline recovery. Co-authored-by: Cursor <cursoragent@cursor.com>
Share global-rank parsing across profile and bypass paths, enforce single-rank validation for explicit files, and derive a finite phase wait from the materialized benchmark timeout. Co-authored-by: Cursor <cursoragent@cursor.com>
Require both measurement and capture success before marking trace input ready, preserve pre-capture errors, and mtime-gate single-node artifacts across retries. Co-authored-by: Cursor <cursoragent@cursor.com>
Skip stale trace discovery after a failed measurement and align TP-rank fixture syntax with the shared parser contract. Co-authored-by: Cursor <cursoragent@cursor.com>
Carry the resolved session decision into runtime preparation and fall back to the materialized AgentX script without weakening lazy imports for synthetic runs. Co-authored-by: Cursor <cursoragent@cursor.com>
ZhengGong-amd
approved these changes
Sep 3, 2026
ZhengGong-amd
left a comment
Collaborator
There was a problem hiding this comment.
Problem resolved, approved
zengleixin-amd
pushed a commit
that referenced
this pull request
Sep 3, 2026
Two conflicts, both in the AgentX preflight path that #1386 also touched. Kept both sides rather than either: * `preflight.py` -- main's structure (the loader-allowlist branch plus the new `require_progress_api` flag check) with this branch's `repairable` marking carried onto all three raise sites. A build missing `--api-host`/`--api-port` is a build the pinned installer can replace, so it is repairable for the same reason the scenario-flag and probe-failure raises are. * `runtime.py` -- main's upgrade-aware memoization (a weak check does not satisfy a later strong one) around this branch's repair. The memo is keyed on the binary that actually passed, which after a repair may be one the install only just put on PATH, and `require_progress_api` is threaded into both capability checks so a profile round's stronger requirement survives the repair. `test_agentx_runtime.py`'s two `require_progress_api` assertions gain `env`: this branch passes the child environment into the capability check so the corpus-pin admission test reads the pin the benchmark will actually run with. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Test plan
python -m pytest -q src/hyperloom/inference_optimizer/tests/test_aiperf_client_sh.pypython -m pytest -q src/hyperloom/inference_optimizer/tests/test_aiperf_phase_gate.py src/hyperloom/inference_optimizer/tests/test_agentx_deploy.py src/hyperloom/inference_optimizer/tests/test_agentx_preflight.py src/hyperloom/inference_optimizer/tests/test_agentx_runtime.py src/hyperloom/inference_optimizer/tests/test_packaging_lint.pyPYTHONPATH=src python -m pytest -q src/hyperloom/inference_optimizer/tests/test_profile_and_kernel_handlers.pyMade with Cursor