Skip to content

[https://nvbugs/6463822][fix] Fix LTX2 CUDA graph test leak issue - #16775

Merged
juney-nvidia merged 1 commit into
NVIDIA:mainfrom
yibinl-nvidia:dev-yibinl-bug6463822-ltx2-cudagraph-leak
Jul 25, 2026
Merged

[https://nvbugs/6463822][fix] Fix LTX2 CUDA graph test leak issue#16775
juney-nvidia merged 1 commit into
NVIDIA:mainfrom
yibinl-nvidia:dev-yibinl-bug6463822-ltx2-cudagraph-leak

Conversation

@yibinl-nvidia

@yibinl-nvidia yibinl-nvidia commented Jul 23, 2026

Copy link
Copy Markdown
Collaborator

Dev Engineer Review

  • Updated _generate_ltx2_cuda_graph_trtllm_backend_video to delete visual_gen and invoke _cleanup_cuda() during teardown.
  • Cleanup is placed in finally, ensuring execution on both success and failure after backend shutdown.
  • No API, configuration, or test-list changes. The change is small and consistent with deterministic CUDA resource cleanup.

QA Engineer Review

  • Modified test function: _generate_ltx2_cuda_graph_trtllm_backend_video.
  • No test-list files were modified; CI coverage mapping could not be confirmed from the available changes.
  • Verdict: needs follow-up.

Description

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)

  • If PR introduces API changes, an appropriate PR label is added - either api-compatible or api-breaking. For api-breaking, include BREAKING in the PR title.

  • 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

To see a list of available CI bot commands, please comment /bot help.

Signed-off-by: Yibin Li <109242046+yibinl-nvidia@users.noreply.github.com>
@yibinl-nvidia

Copy link
Copy Markdown
Collaborator Author

/bot help

@github-actions

Copy link
Copy Markdown

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.

Details

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) --high-priority]

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. Supports wildcard * for pattern matching (e.g., "*PerfSanity*" matches all stages containing PerfSanity). Examples: "A10-PyTorch-1, xxx", "PerfSanity". The patterns "*", "*Post-Merge*", and "*PerfSanity*", including equivalent escaped or repeated-star forms and their use in comma-separated lists, require the ci: post-merge approved PR label. 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. Requires the ci: post-merge approved PR label applied by an active member of NVIDIA/trt-llm-ci-approvers. The approval label remains in place when new commits are pushed.

--extra-stage "H100_PCIe-TensorRT-Post-Merge-1, xxx" (OPTIONAL) : Run the ordinary L0 pre-merge pipeline and specified test stages. Supports wildcard * for pattern matching. Examples: --extra-stage "H100_PCIe-TensorRT-Post-Merge-1, xxx", --extra-stage "Post-Merge". The patterns "*", "*Post-Merge*", and "*PerfSanity*", including equivalent escaped or repeated-star forms and their use in comma-separated lists, require the ci: post-merge approved PR label.

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

--high-priority (OPTIONAL) : Run the pipeline with high priority. This option is restricted to authorized users only and will route the job to a high-priority queue.

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.

@yibinl-nvidia

Copy link
Copy Markdown
Collaborator Author

/bot run --extra-stage "DGX_B200-PyTorch-Post-Merge-2, examples/visual_gen/test_visual_gen.py::test_ltx2_cuda_graph_trtllm_backend"

@tensorrt-cicd

Copy link
Copy Markdown
Collaborator

PR_Github #61350 [ run ] triggered by Bot. Commit: e99490a Link to invocation

@tensorrt-cicd

Copy link
Copy Markdown
Collaborator

PR_Github #61350 [ run ] completed with state FAILURE. Commit: e99490a
/LLM/main/L0_MergeRequest_PR pipeline #49578 completed with status: 'FAILURE'

CI Report

⚠️ Action Required:

  • Please check the failed tests and fix your PR
  • If you cannot view the failures, ask the CI triggerer to share details
  • Once fixed, request an NVIDIA team member to trigger CI again

CI Agent Failure Analysis

Link to invocation

@yibinl-nvidia

Copy link
Copy Markdown
Collaborator Author

/bot run --extra-stage "DGX_B200-PyTorch-Post-Merge-2, examples/visual_gen/test_visual_gen.py::test_ltx2_cuda_graph_trtllm_backend" --disable-fail-fast

@tensorrt-cicd

Copy link
Copy Markdown
Collaborator

PR_Github #61375 [ run ] triggered by Bot. Commit: e99490a Link to invocation

@tensorrt-cicd

Copy link
Copy Markdown
Collaborator

PR_Github #61375 [ run ] completed with state FAILURE. Commit: e99490a
/LLM/main/L0_MergeRequest_PR pipeline #49603 completed with status: 'FAILURE'

CI Report

⚠️ Action Required:

  • Please check the failed tests and fix your PR
  • If you cannot view the failures, ask the CI triggerer to share details
  • Once fixed, request an NVIDIA team member to trigger CI again

CI Agent Failure Analysis

Link to invocation

@yibinl-nvidia

Copy link
Copy Markdown
Collaborator Author

/bot run --extra-stage "DGX_B200-PyTorch-Post-Merge-2" --disable-fail-fast

@tensorrt-cicd

Copy link
Copy Markdown
Collaborator

PR_Github #61403 [ run ] triggered by Bot. Commit: e99490a Link to invocation

@tensorrt-cicd

Copy link
Copy Markdown
Collaborator

PR_Github #61403 [ run ] completed with state SUCCESS. Commit: e99490a
/LLM/main/L0_MergeRequest_PR pipeline #49630 completed with status: 'FAILURE'

CI Report

⚠️ Action Required:

  • Please check the failed tests and fix your PR
  • If you cannot view the failures, ask the CI triggerer to share details
  • Once fixed, request an NVIDIA team member to trigger CI again

CI Agent Failure Analysis

Link to invocation

@yibinl-nvidia

Copy link
Copy Markdown
Collaborator Author

/bot run

@yibinl-nvidia

Copy link
Copy Markdown
Collaborator Author

/bot run --extra-stage "DGX_B200-PyTorch-Post-Merge-2" --disable-fail-fast

@tensorrt-cicd

Copy link
Copy Markdown
Collaborator

PR_Github #61582 [ run ] triggered by Bot. Commit: e99490a Link to invocation

@yibinl-nvidia

Copy link
Copy Markdown
Collaborator Author

/bot kill

@tensorrt-cicd

Copy link
Copy Markdown
Collaborator

PR_Github #61582 [ run ] completed with state FAILURE. Commit: e99490a
/LLM/main/L0_MergeRequest_PR pipeline #49793 completed with status: 'FAILURE'

CI Report

⚠️ Action Required:

  • Please check the failed tests and fix your PR
  • If you cannot view the failures, ask the CI triggerer to share details
  • Once fixed, request an NVIDIA team member to trigger CI again

CI Agent Failure Analysis

Link to invocation

@tensorrt-cicd

Copy link
Copy Markdown
Collaborator

PR_Github #61611 [ kill ] triggered by Bot. Commit: e99490a Link to invocation

@tensorrt-cicd

Copy link
Copy Markdown
Collaborator

PR_Github #61611 [ kill ] completed with state SUCCESS. Commit: e99490a
Successfully killed previous jobs for commit e99490a

Link to invocation

@yibinl-nvidia

Copy link
Copy Markdown
Collaborator Author

/bot run --stage-list "DGX_B200-PyTorch-Post-Merge-2"

@tensorrt-cicd

Copy link
Copy Markdown
Collaborator

PR_Github #61613 [ run ] triggered by Bot. Commit: e99490a Link to invocation

@tensorrt-cicd

Copy link
Copy Markdown
Collaborator

PR_Github #61613 [ run ] completed with state SUCCESS. Commit: e99490a
/LLM/main/L0_MergeRequest_PR pipeline #49820 (Partly Tested) completed with status: 'SUCCESS'

CI Report

Link to invocation

@yibinl-nvidia
yibinl-nvidia marked this pull request as ready for review July 24, 2026 17:57
@yibinl-nvidia
yibinl-nvidia requested review from a team as code owners July 24, 2026 17:57
@coderabbitai

coderabbitai Bot commented Jul 24, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Enterprise

Run ID: fe475f48-00cb-4f0c-b691-502dc882e8de

📥 Commits

Reviewing files that changed from the base of the PR and between 0a401b4 and e99490a.

📒 Files selected for processing (1)
  • tests/integration/defs/examples/visual_gen/test_visual_gen.py

Walkthrough

The TRT-LLM VisualGen CUDA-graph test helper now deletes the backend object and runs CUDA cleanup after shutdown, including when generation exits through the finally path.

Changes

VisualGen CUDA cleanup

Layer / File(s) Summary
Release resources after generation
tests/integration/defs/examples/visual_gen/test_visual_gen.py
The cleanup path deletes visual_gen and calls _cleanup_cuda() after visual_gen.shutdown().

Estimated code review effort: 1 (Trivial) | ~2 minutes

Suggested reviewers: chang-l

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Description check ⚠️ Warning The description is mostly the template with no filled-in issue/solution or test coverage details. Fill in the Description and Test Coverage sections with the problem, the fix, and the relevant test(s); keep the checklist if desired.
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title matches the change: a fix for the LTX2 CUDA graph test leak and includes the NVBugs ID and type.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

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

@schetlur-nv schetlur-nv left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

lgtm

@schetlur-nv schetlur-nv added the ci: post-merge approved Approved by TRT-LLM CI approvers for broad post-merge CI requests label Jul 24, 2026
@yibinl-nvidia

Copy link
Copy Markdown
Collaborator Author

/bot run --stage-list "DGX_B200-PyTorch-Post-Merge-2"

@tensorrt-cicd

Copy link
Copy Markdown
Collaborator

PR_Github #61633 [ run ] triggered by Bot. Commit: e99490a Link to invocation

@tensorrt-cicd

Copy link
Copy Markdown
Collaborator

PR_Github #61633 [ run ] completed with state SUCCESS. Commit: e99490a
/LLM/main/L0_MergeRequest_PR pipeline #49840 (Partly Tested) completed with status: 'SUCCESS'

CI Report

Link to invocation

@yibinl-nvidia

Copy link
Copy Markdown
Collaborator Author

/bot run

@tensorrt-cicd

Copy link
Copy Markdown
Collaborator

PR_Github #61642 [ run ] triggered by Bot. Commit: e99490a Link to invocation

@tensorrt-cicd

Copy link
Copy Markdown
Collaborator

PR_Github #61642 [ run ] completed with state SUCCESS. Commit: e99490a
/LLM/main/L0_MergeRequest_PR pipeline #49849 completed with status: 'SUCCESS'

CI Report

Link to invocation

@BowenFu BowenFu left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

LGTM — test-only cleanup (del + _cleanup_cuda in finally) to release CUDA state after LTX2 CUDA-graph test; no product/default behavior impact.

@juney-nvidia juney-nvidia removed the ci: post-merge approved Approved by TRT-LLM CI approvers for broad post-merge CI requests label Jul 25, 2026
@juney-nvidia
juney-nvidia merged commit bfb0fca into NVIDIA:main Jul 25, 2026
18 of 19 checks passed
yuanjingx87 pushed a commit to yuanjingx87/TensorRT-LLM that referenced this pull request Jul 26, 2026
…IDIA#16775)

Signed-off-by: Yibin Li <109242046+yibinl-nvidia@users.noreply.github.com>
@yibinl-nvidia
yibinl-nvidia deleted the dev-yibinl-bug6463822-ltx2-cudagraph-leak branch July 27, 2026 03:28
hhzhang16 added a commit to hhzhang16/TensorRT-LLM that referenced this pull request Jul 27, 2026
…nnahz/dep-1083-port-flashinfer-stable-va-lifecycle-for-native-all-reduce

* 'main' of https://github.com/NVIDIA/TensorRT-LLM: (54 commits)
  [NVIDIA#15673][fix] Enable CUDA core fast path for SM89/SM120/SM121 (NVIDIA#12705)
  [None][test] Adjust timeout cases in QA perf test (NVIDIA#16894)
  [https://nvbugs/6157892][fix] Mistral format refactor (NVIDIA#15123)
  [None][feat] Add kimi_k2/glm_5 grouped routing and fused router to bench_moe (NVIDIA#16830)
  [https://nvbugs/6501376][fix] Test-only fix — drop the `if hidden_size % 2 != 0: with pytest.raises(...)`… (NVIDIA#16844)
  [TRTLLM-13642][feat] Add perf sanity tests for Llama-3.1-8B and Gemma-3-1B and verify cache transceiver V2 support (NVIDIA#16355)
  [https://nvbugs/6433376][fix] Update the Dense test to mirror the MoE sibling — assert `bfloat16` under… (NVIDIA#16203)
  [None][fix] Resolve NVFP4 mixed-precision base layers for the DSpark draft (NVIDIA#16831)
  [https://nvbugs/6479324][test] Remove waiver for fixed qwen3_5_4b_fp8_stress disaggregated stress test (NVIDIA#16878)
  [https://nvbugs/6507109][infra] Split slow DGX B300 attention unit tests (NVIDIA#16838)
  [None][infra] Waive 21 failed cases for main in post-merge 2862 (NVIDIA#16882)
  [None][perf] prepare_inputs: avoid O(seq_len) get_tokens(0) marshalling on the host (NVIDIA#16791)
  [None][perf] Optimize Blackwell fused MHC half-MMA kernel (NVIDIA#16799)
  [None][infra] Auto-update test durations from OpenSearch (last 7 days)
  [None][perf] Skip DeepGEMM clean_logits in DSA indexer prefill on custom top-k path (NVIDIA#16789)
  [None][feat] Support DeepSeek-V4 in layer_wise_benchmarks (NVIDIA#16774)
  [https://nvbugs/6465993][fix] use attention cache dtype for disaggregated transfer (NVIDIA#16505)
  [https://nvbugs/6463822][fix] Fix LTX2 CUDA graph test leak issue (NVIDIA#16775)
  [https://nvbugs/5948435][chore] Unwaive DeepSeekV3Lite test_nvfp4_4gpus CUTLASS ep4 fp8kv on RTXPro6000D (NVIDIA#16621)
  [TRTLLM-14417][fix] Exclude ADP/cuda-graph dummy requests from speculative-decode acceptance stats (NVIDIA#16571)
  ...

Signed-off-by: Hannah Zhang <hannahz@nvidia.com>
hhzhang16 added a commit to hhzhang16/TensorRT-LLM that referenced this pull request Jul 27, 2026
…nnahz/dep-1082-shared-mnnvl-moe-lifecycle

* 'main' of https://github.com/NVIDIA/TensorRT-LLM: (142 commits)
  [NVIDIA#15673][fix] Enable CUDA core fast path for SM89/SM120/SM121 (NVIDIA#12705)
  [None][test] Adjust timeout cases in QA perf test (NVIDIA#16894)
  [https://nvbugs/6157892][fix] Mistral format refactor (NVIDIA#15123)
  [None][feat] Add kimi_k2/glm_5 grouped routing and fused router to bench_moe (NVIDIA#16830)
  [https://nvbugs/6501376][fix] Test-only fix — drop the `if hidden_size % 2 != 0: with pytest.raises(...)`… (NVIDIA#16844)
  [TRTLLM-13642][feat] Add perf sanity tests for Llama-3.1-8B and Gemma-3-1B and verify cache transceiver V2 support (NVIDIA#16355)
  [https://nvbugs/6433376][fix] Update the Dense test to mirror the MoE sibling — assert `bfloat16` under… (NVIDIA#16203)
  [None][fix] Resolve NVFP4 mixed-precision base layers for the DSpark draft (NVIDIA#16831)
  [https://nvbugs/6479324][test] Remove waiver for fixed qwen3_5_4b_fp8_stress disaggregated stress test (NVIDIA#16878)
  [https://nvbugs/6507109][infra] Split slow DGX B300 attention unit tests (NVIDIA#16838)
  [None][infra] Waive 21 failed cases for main in post-merge 2862 (NVIDIA#16882)
  [None][perf] prepare_inputs: avoid O(seq_len) get_tokens(0) marshalling on the host (NVIDIA#16791)
  [None][perf] Optimize Blackwell fused MHC half-MMA kernel (NVIDIA#16799)
  [None][infra] Auto-update test durations from OpenSearch (last 7 days)
  [None][perf] Skip DeepGEMM clean_logits in DSA indexer prefill on custom top-k path (NVIDIA#16789)
  [None][feat] Support DeepSeek-V4 in layer_wise_benchmarks (NVIDIA#16774)
  [https://nvbugs/6465993][fix] use attention cache dtype for disaggregated transfer (NVIDIA#16505)
  [https://nvbugs/6463822][fix] Fix LTX2 CUDA graph test leak issue (NVIDIA#16775)
  [https://nvbugs/5948435][chore] Unwaive DeepSeekV3Lite test_nvfp4_4gpus CUTLASS ep4 fp8kv on RTXPro6000D (NVIDIA#16621)
  [TRTLLM-14417][fix] Exclude ADP/cuda-graph dummy requests from speculative-decode acceptance stats (NVIDIA#16571)
  ...

Signed-off-by: Hannah Zhang <hannahz@nvidia.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants