Skip to content

Conversation

@lkomali
Copy link

@lkomali lkomali commented Nov 19, 2025

Summary by CodeRabbit

Description

Replace GenAIPerf with AIPerf.

Test Coverage

PR Checklist

Please review the following before submitting your PR:

  • PR description clearly explains what and why. If using CodeRabbit's summary, please make sure it makes sense.

  • PR Follows TRT-LLM CODING GUIDELINES to the best of your knowledge.

  • Test cases are provided for new code paths (see test instructions)

  • Any new dependencies have been scanned for license and vulnerabilities

  • CODEOWNERS updated if ownership changes

  • Documentation updated as needed

  • Update tava architecture diagram if there is a significant design change in PR.

  • The reviewers assigned automatically/manually are appropriate for the PR.

  • Please check this after reviewing the above items as appropriate for this PR.

GitHub Bot Help

/bot [-h] ['run', 'kill', 'skip', 'reuse-pipeline'] ...

Provide a user friendly way for developers to interact with a Jenkins server.

Run /bot [-h|--help] to print this help message.

See details below for each supported subcommand.

run [--reuse-test (optional)pipeline-id --disable-fail-fast --skip-test --stage-list "A10-PyTorch-1, xxx" --gpu-type "A30, H100_PCIe" --test-backend "pytorch, cpp" --add-multi-gpu-test --only-multi-gpu-test --disable-multi-gpu-test --post-merge --extra-stage "H100_PCIe-TensorRT-Post-Merge-1, xxx" --detailed-log --debug(experimental)]

Launch build/test pipelines. All previously running jobs will be killed.

--reuse-test (optional)pipeline-id (OPTIONAL) : Allow the new pipeline to reuse build artifacts and skip successful test stages from a specified pipeline or the last pipeline if no pipeline-id is indicated. If the Git commit ID has changed, this option will be always ignored. The DEFAULT behavior of the bot is to reuse build artifacts and successful test results from the last pipeline.

--disable-reuse-test (OPTIONAL) : Explicitly prevent the pipeline from reusing build artifacts and skipping successful test stages from a previous pipeline. Ensure that all builds and tests are run regardless of previous successes.

--disable-fail-fast (OPTIONAL) : Disable fail fast on build/tests/infra failures.

--skip-test (OPTIONAL) : Skip all test stages, but still run build stages, package stages and sanity check stages. Note: Does NOT update GitHub check status.

--stage-list "A10-PyTorch-1, xxx" (OPTIONAL) : Only run the specified test stages. Examples: "A10-PyTorch-1, xxx". Note: Does NOT update GitHub check status.

--gpu-type "A30, H100_PCIe" (OPTIONAL) : Only run the test stages on the specified GPU types. Examples: "A30, H100_PCIe". Note: Does NOT update GitHub check status.

--test-backend "pytorch, cpp" (OPTIONAL) : Skip test stages which don't match the specified backends. Only support [pytorch, cpp, tensorrt, triton]. Examples: "pytorch, cpp" (does not run test stages with tensorrt or triton backend). Note: Does NOT update GitHub pipeline status.

--only-multi-gpu-test (OPTIONAL) : Only run the multi-GPU tests. Note: Does NOT update GitHub check status.

--disable-multi-gpu-test (OPTIONAL) : Disable the multi-GPU tests. Note: Does NOT update GitHub check status.

--add-multi-gpu-test (OPTIONAL) : Force run the multi-GPU tests in addition to running L0 pre-merge pipeline.

--post-merge (OPTIONAL) : Run the L0 post-merge pipeline instead of the ordinary L0 pre-merge pipeline.

--extra-stage "H100_PCIe-TensorRT-Post-Merge-1, xxx" (OPTIONAL) : Run the ordinary L0 pre-merge pipeline and specified test stages. Examples: --extra-stage "H100_PCIe-TensorRT-Post-Merge-1, xxx".

--detailed-log (OPTIONAL) : Enable flushing out all logs to the Jenkins console. This will significantly increase the log volume and may slow down the job.

--debug (OPTIONAL) : Experimental feature. Enable access to the CI container for debugging purpose. Note: Specify exactly one stage in the stage-list parameter to access the appropriate container environment. Note: Does NOT update GitHub check status.

For guidance on mapping tests to stage names, see docs/source/reference/ci-overview.md
and the scripts/test_to_stage_mapping.py helper.

kill

kill

Kill all running builds associated with pull request.

skip

skip --comment COMMENT

Skip testing for latest commit on pull request. --comment "Reason for skipping build/test" is required. IMPORTANT NOTE: This is dangerous since lack of user care and validation can cause top of tree to break.

reuse-pipeline

reuse-pipeline

Reuse a previous pipeline to validate current commit. This action will also kill all currently running builds associated with the pull request. IMPORTANT NOTE: This is dangerous since lack of user care and validation can cause top of tree to break.

@lkomali lkomali requested review from a team as code owners November 19, 2025 17:53
@coderabbitai
Copy link
Contributor

coderabbitai bot commented Nov 19, 2025

📝 Walkthrough

Walkthrough

The pull request systematically replaces the genai-perf dependency with aiperf across the codebase. Example scripts using genai-perf are deleted, dependencies are updated in configuration files, and references throughout test and integration code are refactored to use aiperf commands and artifacts.

Changes

Cohort / File(s) Summary
Deleted example scripts
examples/serve/genai_perf_client.sh, examples/serve/genai_perf_client_for_multimodal.sh
Removed shell scripts that executed genai-perf profile commands with predefined configurations for standard and multimodal models.
Dependency updates
examples/serve/requirements.txt, requirements-dev.txt
Replaced genai-perf with aiperf (versions updated: 0.0.130.2.0 in dev requirements).
Test parameter updates
tests/unittest/llmapi/apps/_test_trtllm_serve_example.py, tests/unittest/llmapi/apps/_test_trtllm_serve_multimodal_example.py
Changed bash script references in parametrized tests from genai_perf_client.sh and genai_perf_client_for_multimodal.sh to aiperf_client.sh and aiperf_client_for_multimodal.sh respectively.
Stress test integration refactoring
tests/integration/defs/stress_test/stress_test.py
Renamed public functions create_genai_perf_command()create_aiperf_command() and run_genai_perf_process()run_aiperf_process(). Updated command construction, artifact file naming (profile_export_genai_perf.jsonprofile_export_aiperf.json), error messages, and internal logic throughout capacity, stress, and metrics extraction stages to reference aiperf.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20 minutes

  • tests/integration/defs/stress_test/stress_test.py: Requires careful verification that function renames and internal logic changes (artifact file naming, command construction, process management) are consistently applied across all orchestration stages (capacity, stress, and metrics extraction).
  • Dependency version bump (genai-perf==0.0.13aiperf==0.2.0): Verify compatibility and that any API/flag changes between versions are properly reflected in command construction logic.
  • Test parameter updates: Confirm that corresponding bash scripts (aiperf_client.sh, aiperf_client_for_multimodal.sh) exist and are functional replacements for the deleted genai-perf scripts.

Pre-merge checks and finishing touches

❌ Failed checks (1 inconclusive)
Check name Status Explanation Resolution
Description check ❓ Inconclusive PR description is minimal and lacks critical details required by the template, such as specific test coverage, dependency vulnerability scans, and whether CODEOWNERS/documentation updates are needed. Provide more comprehensive PR description including: (1) detailed explanation of why GenAIPerf is being replaced with AIPerf, (2) clear Test Coverage section listing which tests validate the changes, (3) confirmation of completed PR Checklist items (dependency scans, CODEOWNERS updates, documentation updates).
✅ Passed checks (2 passed)
Check name Status Explanation
Docstring Coverage ✅ Passed Docstring coverage is 80.00% which is sufficient. The required threshold is 80.00%.
Title check ✅ Passed The title clearly and concisely summarizes the main change: replacing GenAI-Perf with AIPerf. It is specific, directly related to the substantial modifications across multiple files, and uses clear terminology.
✨ Finishing touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment

Tip

📝 Customizable high-level summaries are now available in beta!

You can now customize how CodeRabbit generates the high-level summary in your pull requests — including its content, structure, tone, and formatting.

  • Provide your own instructions using the high_level_summary_instructions setting.
  • Format the summary however you like (bullet lists, tables, multi-section layouts, contributor stats, etc.).
  • Use high_level_summary_in_walkthrough to move the summary from the description to the walkthrough section.

Example instruction:

"Divide the high-level summary into five sections:

  1. 📝 Description — Summarize the main change in 50–60 words, explaining what was done.
  2. 📓 References — List relevant issues, discussions, documentation, or related PRs.
  3. 📦 Dependencies & Requirements — Mention any new/updated dependencies, environment variable changes, or configuration updates.
  4. 📊 Contributor Summary — Include a Markdown table showing contributions:
    | Contributor | Lines Added | Lines Removed | Files Changed |
  5. ✔️ Additional Notes — Add any extra reviewer context.
    Keep each section concise (under 200 words) and use bullet or numbered lists for clarity."

Note: This feature is currently in beta for Pro-tier users, and pricing will be announced later.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 0

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
tests/integration/defs/stress_test/stress_test.py (1)

51-69: Remove stale aiperf installation stub and noqa directive

The commented‑out aiperf_install() helper and the commented import aiperf # noqa: F401 are now misleading (you’ve moved installation into requirements) and Ruff flags the unused noqa directive (RUF100).

Consider fully deleting the dead helper and the commented import, or rewriting the surrounding comments to describe the current installation strategy without using a noqa marker. This will keep the stress test script aligned with the new dependency model and avoid unnecessary lint noise.

Also applies to: 429-433

🧹 Nitpick comments (2)
examples/serve/requirements.txt (1)

1-1: Consider aligning aiperf version here with dev requirements

This example file pulls in the latest aiperf while requirements-dev.txt pins aiperf==0.2.0. That’s fine if you want examples to track latest releases, but it can also introduce behavior drift from your tested dev setup.

If you prefer reproducibility, consider pinning or at least lower‑bounding the version here (e.g., aiperf==0.2.0 or aiperf>=0.2.0) to match what you run in CI.

tests/integration/defs/stress_test/stress_test.py (1)

157-182: aiperf integration flow looks coherent; verify CLI and artifact schema assumptions

The refactor from genai‑perf to aiperf is internally consistent: PerformanceParams now documents aiperf usage; create_aiperf_command centralizes the CLI, and both measure_capacity_stage and stress_stage call into run_aiperf_process, which in turn monitors both the aiperf process and server health. extract_stress_test_metrics has been updated to expect profile_export_aiperf.json artifacts and to mention aiperf in its validation errors.

  • Ruff TRY003: the long RuntimeError / ValueError messages you updated to reference aiperf (e.g., timeout, non‑zero exit code, “Please check OutputTokenThroughput from aiperf”) are now flagged by Ruff. If TRY003 is enforced, consider either shortening these messages or moving the detailed text into logging and raising simpler exceptions.
  • Behavior assumptions: this code assumes (a) the aiperf CLI supports the profile subcommand and all flags used in create_aiperf_command, and (b) the exported JSON still exposes request_throughput, output_token_throughput, and the same input_config layout. Those look like direct translations from the previous genai‑perf integration but are worth validating end‑to‑end.

Please run a full stress test (including the performance stages) with aiperf and confirm that:

  • the constructed command runs without argument errors,
  • artifacts named profile_export_aiperf.json are generated under ./artifacts/..., and
  • extract_stress_test_metrics succeeds in parsing throughput and concurrency without raising the new aiperf‑specific errors.

Also applies to: 407-428, 757-888, 890-940, 972-1035, 1186-1194, 1300-1313

📜 Review details

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 7ab02ad and 9c41927.

📒 Files selected for processing (7)
  • examples/serve/genai_perf_client.sh (0 hunks)
  • examples/serve/genai_perf_client_for_multimodal.sh (0 hunks)
  • examples/serve/requirements.txt (1 hunks)
  • requirements-dev.txt (1 hunks)
  • tests/integration/defs/stress_test/stress_test.py (20 hunks)
  • tests/unittest/llmapi/apps/_test_trtllm_serve_example.py (1 hunks)
  • tests/unittest/llmapi/apps/_test_trtllm_serve_multimodal_example.py (1 hunks)
💤 Files with no reviewable changes (2)
  • examples/serve/genai_perf_client_for_multimodal.sh
  • examples/serve/genai_perf_client.sh
🧰 Additional context used
🧠 Learnings (5)
📚 Learning: 2025-07-28T17:06:08.621Z
Learnt from: moraxu
Repo: NVIDIA/TensorRT-LLM PR: 6303
File: tests/integration/test_lists/qa/examples_test_list.txt:494-494
Timestamp: 2025-07-28T17:06:08.621Z
Learning: In TensorRT-LLM testing, it's common to have both CLI flow tests (test_cli_flow.py) and PyTorch API tests (test_llm_api_pytorch.py) for the same model. These serve different purposes: CLI flow tests validate the traditional command-line workflow, while PyTorch API tests validate the newer LLM API backend. Both are legitimate and should coexist.

Applied to files:

  • tests/unittest/llmapi/apps/_test_trtllm_serve_multimodal_example.py
  • tests/integration/defs/stress_test/stress_test.py
  • tests/unittest/llmapi/apps/_test_trtllm_serve_example.py
📚 Learning: 2025-09-09T09:40:45.658Z
Learnt from: fredricz-20070104
Repo: NVIDIA/TensorRT-LLM PR: 7645
File: tests/integration/test_lists/qa/llm_function_core.txt:648-648
Timestamp: 2025-09-09T09:40:45.658Z
Learning: In TensorRT-LLM test lists, it's common and intentional for the same test to appear in multiple test list files when they serve different purposes (e.g., llm_function_core.txt for comprehensive core functionality testing and llm_function_core_sanity.txt for quick sanity checks). This duplication allows tests to be run in different testing contexts.

Applied to files:

  • tests/unittest/llmapi/apps/_test_trtllm_serve_multimodal_example.py
  • tests/integration/defs/stress_test/stress_test.py
  • tests/unittest/llmapi/apps/_test_trtllm_serve_example.py
📚 Learning: 2025-08-06T13:58:07.506Z
Learnt from: galagam
Repo: NVIDIA/TensorRT-LLM PR: 6487
File: tests/unittest/_torch/auto_deploy/unit/singlegpu/test_ad_trtllm_bench.py:1-12
Timestamp: 2025-08-06T13:58:07.506Z
Learning: In TensorRT-LLM, test files (files under tests/ directories) do not require NVIDIA copyright headers, unlike production source code files. Test files typically start directly with imports, docstrings, or code.

Applied to files:

  • tests/unittest/llmapi/apps/_test_trtllm_serve_multimodal_example.py
  • tests/integration/defs/stress_test/stress_test.py
  • tests/unittest/llmapi/apps/_test_trtllm_serve_example.py
📚 Learning: 2025-09-17T06:01:01.836Z
Learnt from: fredricz-20070104
Repo: NVIDIA/TensorRT-LLM PR: 7785
File: tests/integration/defs/perf/utils.py:321-333
Timestamp: 2025-09-17T06:01:01.836Z
Learning: In test infrastructure code for disaggregated serving tests, prefer logging errors and continuing execution rather than raising exceptions on timeout, to avoid disrupting test cleanup and causing cascading failures.

Applied to files:

  • tests/integration/defs/stress_test/stress_test.py
📚 Learning: 2025-08-26T09:49:04.956Z
Learnt from: pengbowang-nv
Repo: NVIDIA/TensorRT-LLM PR: 7192
File: tests/integration/test_lists/test-db/l0_dgx_b200.yml:56-72
Timestamp: 2025-08-26T09:49:04.956Z
Learning: In TensorRT-LLM test configuration files, the test scheduling system handles wildcard matching with special rules that prevent duplicate test execution even when the same tests appear in multiple yaml files with overlapping GPU wildcards (e.g., "*b200*" and "*gb200*").

Applied to files:

  • tests/unittest/llmapi/apps/_test_trtllm_serve_example.py
🧬 Code graph analysis (1)
tests/integration/defs/stress_test/stress_test.py (1)
tests/integration/defs/trt_test_alternative.py (1)
  • print_info (300-306)
🪛 Ruff (0.14.5)
tests/integration/defs/stress_test/stress_test.py

432-432: Unused noqa directive (non-enabled: F401)

Remove unused noqa directive

(RUF100)


847-848: Avoid specifying long messages outside the exception class

(TRY003)


877-878: Avoid specifying long messages outside the exception class

(TRY003)


884-885: Avoid specifying long messages outside the exception class

(TRY003)


1310-1311: Avoid specifying long messages outside the exception class

(TRY003)

🔇 Additional comments (3)
requirements-dev.txt (1)

33-33: aiperf dev dependency pin looks reasonable

Replacing genai-perf with aiperf==0.2.0 in dev requirements is consistent with the PR’s migration and the rest of this file’s pinned tooling.

Please double‑check that 0.2.0 is the version you’ve validated in CI and local environments and that it’s compatible with the Triton/PyTorch versions you target.

tests/unittest/llmapi/apps/_test_trtllm_serve_example.py (1)

51-58: Switch to aiperf_client.sh in serve examples test looks correct

The parametrized test now exercises aiperf_client.sh alongside the existing Python and curl clients, which matches the overall migration away from genai‑perf.

Please confirm that examples/serve/aiperf_client.sh is present, executable, and uses the same port/model assumptions as this test (fixed port 8000 and the TinyLlama example) so CI doesn’t fail on missing or misconfigured scripts.

tests/unittest/llmapi/apps/_test_trtllm_serve_multimodal_example.py (1)

61-64: Multimodal example now correctly targets aiperf client script

Using aiperf_client_for_multimodal.sh here is consistent with the rest of the migration and keeps the multimodal example under the same test harness.

Please verify that examples/serve/aiperf_client_for_multimodal.sh exists, is executable, and matches the Qwen2.5‑VL example configuration used by this test so the subprocess call succeeds under CI.

@lkomali lkomali force-pushed the lkomali/replace-gap-with-aiperf branch from b33047c to 697f821 Compare November 19, 2025 18:02
@lkomali lkomali requested review from a team as code owners November 19, 2025 18:02
@lkomali lkomali force-pushed the lkomali/replace-gap-with-aiperf branch from 979f03f to 43e3d8f Compare November 19, 2025 18:06
@svc-trtllm-gh-bot svc-trtllm-gh-bot added the Community want to contribute PRs initiated from Community label Nov 19, 2025
@kaiyux kaiyux changed the title feat: Replace GenAI-Perf with AIPerf [TRTLLM-9091] [feat] Replace GenAI-Perf with AIPerf Nov 20, 2025
@kaiyux
Copy link
Member

kaiyux commented Nov 20, 2025

/bot run

@tensorrt-cicd
Copy link
Collaborator

PR_Github #25171 [ run ] triggered by Bot. Commit: 43e3d8f

@tensorrt-cicd
Copy link
Collaborator

PR_Github #25171 [ run ] completed with state FAILURE. Commit: 43e3d8f
/LLM/main/L0_MergeRequest_PR pipeline #19032 completed with status: 'FAILURE'

Copy link
Member

@kaiyux kaiyux Nov 20, 2025

Choose a reason for hiding this comment

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

I assume we need to update ATTRIBUTIONS-Python.md for this PR? @chzblych @NVIDIA/trt-llm-oss-compliance

@kaiyux kaiyux force-pushed the lkomali/replace-gap-with-aiperf branch from 43e3d8f to 9ad4e9e Compare November 20, 2025 14:12
@kaiyux
Copy link
Member

kaiyux commented Nov 20, 2025

/bot run

@tensorrt-cicd
Copy link
Collaborator

PR_Github #25210 [ run ] triggered by Bot. Commit: 9ad4e9e

@tensorrt-cicd
Copy link
Collaborator

PR_Github #25210 [ run ] completed with state FAILURE. Commit: 9ad4e9e
/LLM/main/L0_MergeRequest_PR pipeline #19065 completed with status: 'FAILURE'

@lkomali lkomali force-pushed the lkomali/replace-gap-with-aiperf branch from 9ad4e9e to 43e3d8f Compare November 21, 2025 19:06
@lkomali lkomali force-pushed the lkomali/replace-gap-with-aiperf branch from 43e3d8f to c94525c Compare November 21, 2025 19:07
@lkomali
Copy link
Author

lkomali commented Nov 21, 2025

/bot run

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

Labels

Community want to contribute PRs initiated from Community

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants