[None][fix] fix CppMambaHybridCacheManager to handle dp dummy request
… correctly
Summary by CodeRabbit
-
Bug Fixes
- Improved recurrent-state block index initialization to process only newly added requests, preventing stale state data.
-
Tests
- Updated test configuration for disaggregated serving scenarios to better cover corner cases on various hardware configurations.
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-compatibleorapi-breaking. Forapi-breaking, includeBREAKINGin 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.
-
[x] 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.
📝 Walkthrough
Walkthrough
The PR refactors Mamba hybrid cache state-index setup to accept an optional request list, enabling efficient per-request initialization. Call sites now pass newly added requests explicitly, avoiding redundant recomputation. Test configuration updates enable the Nemotron3Super120B suite with a corner-case batch-size setting.
Changes
Mamba state index computation optimization
| Layer / File(s) | Summary |
|---|---|
State indices method refactor and call site update tensorrt_llm/_torch/pyexecutor/mamba_cache_manager.py |
_setup_state_indices() now accepts an optional requests parameter and computes block indices, uploads offsets, and builds request mappings from that list. add_dummy_requests() updated to pass only newly added requests, eliminating stale-state recomputation in the recurrent-state setup path. |
Nemotron test configuration and skip decorator update tests/integration/defs/accuracy/test_disaggregated_serving.py |
@skip_pre_blackwell decorator removed from TestNemotron3Super120B. Context server config in test_ctx_dp2_gen_tp4 updated with max_batch_size = 1 to test dp dummy-requests corner case against the refactored state-indices path. |
Estimated code review effort
🎯 2 (Simple) | ⏱️ ~12 minutes
Possibly related PRs
- NVIDIA/TensorRT-LLM#14853: Modifies dummy-request handling in the same cache manager module; the state-index refactoring here directly complements attention-DP dummy-slot reservation logic.
Suggested reviewers
- danielafrimi
- symphonylyh
- achartier
- HuiGao-NV
- nv-guomingz
🚥 Pre-merge checks | ✅ 4 | ❌ 1
❌ Failed checks (1 warning)
| Check name | Status | Explanation | Resolution |
|---|---|---|---|
| Description check | ⚠️ Warning | The PR description is almost entirely empty, containing only template text with no substantive content explaining the issue or solution. | Add a detailed description explaining the bug with dp dummy requests, why the current implementation fails, and how the changes fix the issue. Include test coverage information and confirm PR checklist items are addressed. |
✅ Passed checks (4 passed)
| Check name | Status | Explanation |
|---|---|---|
| Title check | ✅ Passed | The title clearly identifies the main fix: handling dp dummy requests in CppMambaHybridCacheManager, which aligns with the code changes made. |
| 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. |
✏️ 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.
/bot run --add-multi-gpu-test --disable-fail-fast
PR_Github #52632 [ run ] triggered by Bot. Commit: adc4daa Link to invocation
PR_Github #52632 [ run ] completed with state SUCCESS. Commit: adc4daa
/LLM/main/L0_MergeRequest_PR pipeline #41912 completed with status: 'FAILURE'
⚠️ 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
/bot run --add-multi-gpu-test --disable-fail-fast
PR_Github #52906 [ run ] triggered by Bot. Commit: adc4daa Link to invocation
PR_Github #52906 [ run ] completed with state SUCCESS. Commit: adc4daa
/LLM/main/L0_MergeRequest_PR pipeline #42152 completed with status: 'FAILURE'
⚠️ 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
/bot run
PR_Github #53062 [ run ] triggered by Bot. Commit: adc4daa Link to invocation
PR_Github #53062 [ run ] completed with state FAILURE. Commit: adc4daa
/LLM/main/L0_MergeRequest_PR pipeline #42276 completed with status: 'FAILURE'
⚠️ 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
/bot run
PR_Github #53118 [ run ] triggered by Bot. Commit: adc4daa Link to invocation
PR_Github #53118 [ run ] completed with state FAILURE. Commit: adc4daa
/LLM/main/L0_MergeRequest_PR pipeline #42325 completed with status: 'FAILURE'
⚠️ 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
/bot run
PR_Github #53129 [ run ] triggered by Bot. Commit: adc4daa Link to invocation
PR_Github #53129 [ run ] completed with state FAILURE. Commit: adc4daa
/LLM/main/L0_MergeRequest_PR pipeline #42335 completed with status: 'FAILURE'
⚠️ 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
/bot run
PR_Github #53139 [ run ] triggered by Bot. Commit: adc4daa Link to invocation
PR_Github #53139 [ run ] completed with state FAILURE. Commit: adc4daa
/LLM/main/L0_MergeRequest_PR pipeline #42343 completed with status: 'FAILURE'
⚠️ 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
/bot run