Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

[None][fix] NVTX annotation in sampler.py#12459

Merged
Funatiq merged 1 commit intoNVIDIA:mainNVIDIA/TensorRT-LLM:mainfrom
ixlmar:fix/nvtx-annotationixlmar/TensorRT-LLM:fix/nvtx-annotationCopy head branch name to clipboard
Mar 27, 2026
Merged

[None][fix] NVTX annotation in sampler.py#12459
Funatiq merged 1 commit intoNVIDIA:mainNVIDIA/TensorRT-LLM:mainfrom
ixlmar:fix/nvtx-annotationixlmar/TensorRT-LLM:fix/nvtx-annotationCopy head branch name to clipboard

Conversation

@ixlmar
Copy link
Copy Markdown
Collaborator

@ixlmar ixlmar commented Mar 23, 2026

Description

Avoids error during profiling.

Test Coverage

n/a

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

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

Summary by CodeRabbit

  • Refactor
    • Adjusted internal code organization for improved maintainability.

@ixlmar ixlmar requested a review from a team as a code owner March 23, 2026 14:22
@ixlmar ixlmar requested a review from achartier March 23, 2026 14:22
@ixlmar
Copy link
Copy Markdown
Collaborator Author

ixlmar commented Mar 23, 2026

/bot run

@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai Bot commented Mar 23, 2026

📝 Walkthrough

Walkthrough

The @nvtx_range decorator on the _update_original_tokens static method in TorchSampler was repositioned to appear below the @staticmethod decorator rather than above it. The method signature and implementation remain unchanged.

Changes

Cohort / File(s) Summary
Decorator Reordering
tensorrt_llm/_torch/pyexecutor/sampler.py
Reordered decorators on _update_original_tokens: moved @nvtx_range to appear directly below @staticmethod.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~2 minutes

🚥 Pre-merge checks | ✅ 2 | ❌ 1

❌ Failed checks (1 inconclusive)

Check name Status Explanation Resolution
Description check ❓ Inconclusive The PR description is vague and lacks specific technical details about the decorator reordering change and its impact on profiling. Clarify what specific profiling error is avoided, explain why reordering the decorators fixes it, and provide more context about the technical rationale.
✅ Passed checks (2 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly and specifically describes the main change: fixing NVTX annotation in sampler.py, which aligns with the file modification and objective of avoiding profiling errors.
Docstring Coverage ✅ Passed Docstring coverage is 100.00% which is sufficient. The required threshold is 80.00%.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

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

Copy link
Copy Markdown
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.

🧹 Nitpick comments (1)
tensorrt_llm/_torch/pyexecutor/sampler.py (1)

2335-2341: Add a regression test for the staticmethod + NVTX decorator contract.

The decorator reordering looks correct, but this is easy to accidentally regress. Please add a targeted test that calls TorchSampler._update_original_tokens(...) under profiling/NVTX-enabled execution and asserts it does not raise.


ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 5987ffb6-4602-4565-be70-b92d60f6167d

📥 Commits

Reviewing files that changed from the base of the PR and between bdd8558 and 8db4bf1.

📒 Files selected for processing (1)
  • tensorrt_llm/_torch/pyexecutor/sampler.py

@tensorrt-cicd
Copy link
Copy Markdown
Collaborator

PR_Github #39946 [ run ] triggered by Bot. Commit: 8db4bf1 Link to invocation

@tensorrt-cicd
Copy link
Copy Markdown
Collaborator

PR_Github #39946 [ run ] completed with state SUCCESS. Commit: 8db4bf1
/LLM/main/L0_MergeRequest_PR pipeline #31111 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

Link to invocation

@ixlmar
Copy link
Copy Markdown
Collaborator Author

ixlmar commented Mar 24, 2026

/bot run

@tensorrt-cicd
Copy link
Copy Markdown
Collaborator

PR_Github #40092 [ run ] triggered by Bot. Commit: 8db4bf1 Link to invocation

@tensorrt-cicd
Copy link
Copy Markdown
Collaborator

PR_Github #40092 [ run ] completed with state FAILURE. Commit: 8db4bf1
/LLM/main/L0_MergeRequest_PR pipeline #31244 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

Link to invocation

@ixlmar ixlmar force-pushed the fix/nvtx-annotation branch from 8db4bf1 to c4e8923 Compare March 24, 2026 13:53
@ixlmar
Copy link
Copy Markdown
Collaborator Author

ixlmar commented Mar 24, 2026

/bot run

@tensorrt-cicd
Copy link
Copy Markdown
Collaborator

PR_Github #40122 [ run ] triggered by Bot. Commit: c4e8923 Link to invocation

@ixlmar ixlmar force-pushed the fix/nvtx-annotation branch from c4e8923 to 57060e8 Compare March 24, 2026 15:16
@ixlmar
Copy link
Copy Markdown
Collaborator Author

ixlmar commented Mar 24, 2026

/bot run

@tensorrt-cicd
Copy link
Copy Markdown
Collaborator

PR_Github #40142 [ run ] triggered by Bot. Commit: 57060e8 Link to invocation

@tensorrt-cicd
Copy link
Copy Markdown
Collaborator

PR_Github #40142 [ run ] completed with state SUCCESS. Commit: 57060e8
/LLM/main/L0_MergeRequest_PR pipeline #31288 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

Link to invocation

Signed-off-by: ixlmar <206748156+ixlmar@users.noreply.github.com>
@ixlmar ixlmar force-pushed the fix/nvtx-annotation branch from 57060e8 to c82e5b8 Compare March 25, 2026 07:59
@ixlmar
Copy link
Copy Markdown
Collaborator Author

ixlmar commented Mar 25, 2026

/bot run

@tensorrt-cicd
Copy link
Copy Markdown
Collaborator

PR_Github #40290 [ run ] triggered by Bot. Commit: c82e5b8 Link to invocation

@ixlmar
Copy link
Copy Markdown
Collaborator Author

ixlmar commented Mar 25, 2026

/bot run

@tensorrt-cicd
Copy link
Copy Markdown
Collaborator

PR_Github #40350 [ run ] triggered by Bot. Commit: c82e5b8 Link to invocation

@tensorrt-cicd
Copy link
Copy Markdown
Collaborator

PR_Github #40290 [ run ] completed with state ABORTED. Commit: c82e5b8
/LLM/main/L0_MergeRequest_PR pipeline #31402 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

Link to invocation

@tensorrt-cicd
Copy link
Copy Markdown
Collaborator

PR_Github #40350 [ run ] completed with state SUCCESS. Commit: c82e5b8
/LLM/main/L0_MergeRequest_PR pipeline #31454 completed with status: 'SUCCESS'

CI Report

Link to invocation

@Funatiq Funatiq merged commit 74a27e8 into NVIDIA:main Mar 27, 2026
5 checks passed
@ixlmar ixlmar deleted the fix/nvtx-annotation branch March 30, 2026 08:51
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.

5 participants

Morty Proxy This is a proxified and sanitized view of the page, visit original site.