Repository navigation
Conversation
…rrent trtllm-gen NVIDIA#21997 generated the 4 stage-KV cubins (SM100/SM103 only) with the trtllm-gen libraries from before NVIDIA#22089, so they still read the sequence lengths before griddepcontrol.wait: the PDL race that NVIDIA#22089 fixed in all other FMHA cubins. Regenerate them with gen_stage_kv_cubins.py on GB200 and GB300. Kernel selection and launch configuration are unchanged, and the archives keep the tar metadata of the existing ones. Remove the B200/B300 waivers of the stage-KV consistency test, which passes again. Signed-off-by: zhixinl <zhixinl@nvidia.com>
The stage-KV hash and header tests only read repository files, but they sat in the Blackwell-only GPU module. Move them to tests/unittest/scripts, which the CPU pre-merge stage runs, and make the consistency test's failure say what is stale and how to regenerate the cubins. Signed-off-by: zhixinl <zhixinl@nvidia.com>
|
Note Reviews pausedIt looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the
Use the following commands to manage reviews:
Use the checkboxes below for quick actions:
No actionable comments were generated in the recent review. WalkthroughThe SM100 and SM103 stage-KV metadata records have updated kernel hashes. CPU-only script tests now check hash consistency and generator behavior. The integration waiver list has additions and removals. ChangesStage-KV hash consistency
Integration test waivers
Estimated code review effort: 2 (Simple) | ~10 minutes Change: Bug fix Suggested reviewers: Merge Risk:
|
…he generator spec_from_file_location can return None, which pyrefly flags. Assert it as tests/unittest/scripts/test_check_pip_install.py does. Signed-off-by: zhixinl <zhixinl@nvidia.com>
|
@yunruis, could you help to review this PR as trt-llm-torch-attention-devs? Thanks~ Assignment explanation
Affinity and workload are snapshots at selection, not live counters. Existing reservations on this PR are counted once. |
|
/bot run |
|
please update wiki doc in trtllm-gen |
|
PR_Github #88347 [ run ] triggered by Bot. Commit: |
yunruis
left a comment
There was a problem hiding this comment.
The attention part LGTM.
|
Automatically added "ci: full pre-merge approved" because this PR has satisfied the required GitHub review approvals. Unresolved review conversations and other required checks remain independent merge requirements. |
|
PR_Github #88347 [ run ] completed with state
|
trtllm-agent-review
left a comment
There was a problem hiding this comment.
Thanks for the PR. It regenerates the four SM100/SM103 stage-KV FMHA cubins with the current trtllm-gen, so they wait for the PDL predecessor before reading sequence lengths, moves their file-only hash tests to CPU pre-merge and drops the two B200/B300 waives.
Reviewed at commit bd179a5620 (9 files, +149/−112).
The four archives were fetched from LFS and disassembled for the SASS check.
Approve: no Blocker found. 3 suggestions below are nice to have.
Nice to have (3): 3 inline, 0 below
- (N3: Missing or ineffective tests) This check hashes only the trtllm-gen export headers, so a trtllm-gen update that changes only the generator libraries leaves the four stage-KV cubins stale while CPU pre-merge stays green. (test_gen_stage_kv_cubins.py:60)
- (R3: Repository rules) The new test file's functions have no annotations, against CODING_GUIDELINES.md's "Always annotate functions". (test_gen_stage_kv_cubins.py:25)
- (R1: PR process) #22611 is a competing fix for the same bug on the same files: close it when this PR merges, and decide what happens to its write_archive change. (test_gen_stage_kv_cubins.py:1)
What this review checked
- The moved hash test fails against the base revision's kernelMetaInfoStageKv.h, which records 3e76c3ff… while the headers now hash to 1ff5959e…, and prints the new regenerate message. All five moved cases pass at this commit, and the unittest/scripts entry of l0_cpu.yml selects them.
- Each of the four new archives holds one cubin whose sha256 matches its entry in kernelMetaInfoStageKv.h, and the header is byte-identical to #22611's. In the new SASS no global or TMA load comes before the first griddepcontrol.wait; the old cubins had eight.
- Both removed waives cite this PR's bug, and no test list, QA list, duration entry or other waive still names the old test ids.
- Not covered: No GPU run: the regenerated cubins were not executed, and the B200/B300 pre-merge results were not yet available.
- Not covered: The E4 softmax-loop reordering was not checked in the SASS.
Automated review by trtllm-agent-review. If a point is wrong, reply in its thread. Once you have pushed code changes and replied in every Blocker thread, the bot re-checks the Blockers within a few hours. A Blocker you think should not be fixed needs no code change: reply in its thread with the reason and the evidence.
|
What this PR changes, by code owner For each code owner (a team or a person) of files this PR changes: what it changes there. The review above has the findings.
Files
Files
Other files · 1 file Files
|
CODING_GUIDELINES.md asks to annotate every function. Signed-off-by: zhixinl <zhixinl@nvidia.com>
|
/bot run |
|
PR_Github #88378 [ run ] triggered by Bot. Commit: |
|
PR_Github #88378 [ run ] completed with state |
Signed-off-by: zhixinl <zhixinl@nvidia.com>
dc3671
left a comment
There was a problem hiding this comment.
LGTM. Regenerating the four stage-KV cubins is the right fix for 7114472; the merge from main after the last CI run does not touch the FMHA kernel inputs the hash covers.
|
/bot run |
|
PR_Github #88887 [ run ] triggered by Bot. Commit: |
|
PR_Github #88887 [ run ] completed with state Resource maintenance in LLM/main/L0_Test-x86_64-Single-GPU #5743: AWS-PDX-SLURM-1 is unavailable for maintenance on 2026-12-02 17:00-23:00 UTC; H100_PCIe-PyTorch-Perf-1 was retired from main.
|
Description
The 4 stage-KV FMHA cubins from #21997 were generated before #22089 updated trtllm-gen, so they still read the sequence lengths before griddepcontrol.wait (the PDL race #22089 fixed in the other FMHA cubins). test_stage_kv_cubins_match_the_kernel_inputs_they_were_built_against fails on main and is waived on B200/B300.
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.
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.Dev Engineer Review
FmhaSm100a/FmhaSm103a*StageKv256E4.cubin.tar.zstarchives are binary. Numstat shows 2 added and 2 removed lines each, so the payloads cannot be reviewed in the diff.kernelMetaInfoStageKv.h(+6/-6) updates per-kernel SHA-256 values for four entries. Configurations and kernel references are unchanged.gen_stage_kv_cubins.py(+1/-1) changes only the hash-input comment, which now points totest_gen_stage_kv_cubins.py.griddepcontrol.wait) rests on author-reported SASS inspection. The diff does not verify it.#22611artifacts is author-reported only.bd179a5and the later passing run for83ecd65are not verifiable from the diff.QA Engineer Review
test_fmha_paged_context_fp8.py(-95): removes the stage-KV cubin hash-match test, the parametrized hash-coverage test, and the regeneration test.tests/unittest/scripts/test_gen_stage_kv_cubins.py(+138): new CPU-only file. It covers recorded hash matching, hash changes after header edits, header-block preservation, and stale-archive removal.waives.txt(+0/-2): removes theDGX_B200andDGX_B300skips fortest_stage_kv_cubins_match_the_kernel_inputs_they_were_built_against(nvbugs/7114472). No entries are added. The earlier raw-summary claim of four added entries is incorrect.tests/integration/test_lists/test-db/l0_cpu.ymllistsunittest/scripts(line 558), so the new CPU file is collected by that entry.test_fmha_paged_context_fp8.pycases on GB200 and GB300. This is not CI evidence.Per-File QA Perspective
kernelMetaInfoStageKv.h: hash values change for four kernels. QA should confirm kernel selection and launch settings are unchanged.gen_stage_kv_cubins.py: comment only. No QA impact.waives.txt: two skips removed. QA should confirm the FP8 paged-context tests pass on B200 and B300.test_fmha_paged_context_fp8.py: hash and regeneration tests removed. Coverage moves to the new CPU file.test_gen_stage_kv_cubins.py: new CPU-only tests. Covered by theunittest/scriptsentry inl0_cpu.yml.