[None][test] Run thop custom-op schema checks in the CPU pre-merge stage - #17322
Conversation
tests/unittest/_torch/thop/parallel_hw_agnostic/test_custom_ops.py only imports tensorrt_llm and walks the torch schema registry to validate custom-op schemas and fake-impl registration; it does not need a GPU. Mark it cpu_only and add it to l0_cpu.yml so it runs in the CPU-Generic pre-merge stage on every pipeline. The existing unittest/_torch/thop/parallel_hw_agnostic directory entry in l0_h100.yml is unchanged; the cpu_only marker deselects this file there since GPU stages run with -m "not cpu_only". Signed-off-by: Brian Nguyen <brnguyen@nvidia.com>
|
/bot run --stage-list "CPU-Generic-x86-1, CPU-Generic-arm-1" |
|
PR_Github #64128 [ run ] triggered by Bot. Commit: |
|
PR_Github #64128 [ run ] completed with state |
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Enterprise Run ID: 📒 Files selected for processing (1)
🚧 Files skipped from review as they are similar to previous changes (1)
WalkthroughThe custom operations test is marked for CPU-only execution and added to the ChangesCPU test integration
Estimated code review effort: 1 (Trivial) | ~2 minutes Possibly related PRs
Suggested reviewers: 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@tests/unittest/_torch/thop/parallel_hw_agnostic/test_custom_ops.py`:
- Around line 7-8: Add the standard NVIDIA copyright header at the top of
test_custom_ops.py, using 2026 as the latest meaningful modification year and
preserving the existing pytestmark declaration.
🪄 Autofix
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Enterprise
Run ID: 0b03b2ff-159e-4ab1-a044-2602088d3866
📒 Files selected for processing (2)
tests/integration/test_lists/test-db/l0_cpu.ymltests/unittest/_torch/thop/parallel_hw_agnostic/test_custom_ops.py
Signed-off-by: Brian Nguyen <brnguyen@nvidia.com>
|
/bot run --stage-list "CPU-Generic-x86-1, CPU-Generic-arm-1" |
|
/bot run --stage-list "CPU-Generic-x86-1,CPU-Generic-arm-1" |
|
PR_Github #64220 [ run ] triggered by Bot. Commit: |
|
PR_Github #64220 [ run ] completed with state |
|
/bot skip --comment "Two-file test-infra change: marks the hw-agnostic custom-op schema test module cpu_only and lists it in l0_cpu.yml. The stages that newly run it (CPU-Generic-x86-1, CPU-Generic-arm-1) passed on this exact head in pipeline 52127; the only effect on GPU stages is standard -m 'not cpu_only' deselection of one module, the same mechanism used by all existing cpu_only tests (pattern of #17290). No production code changed." |
|
PR_Github #64335 [ skip ] triggered by Bot. Commit: |
|
PR_Github #64335 [ skip ] completed with state |
Description
tests/unittest/_torch/thop/parallel_hw_agnostic/test_custom_ops.py(custom-op schema checks, includingtest_register_fake) is fully GPU-free: it only importstensorrt_llmand walks the torch schema registry. Today it runs only through the H100 test list, so a missing fake/meta implementation for a new C++ custom op is caught late and only on Hopper stages (this happened with a recently added op, where every non-H100 stage stayed green).This PR marks the module
cpu_onlyand adds it tol0_cpu.yml, so the check runs in the CPU-Generic pre-merge stages on every pipeline, independent of GPU pool availability. Thel0_h100.ymldirectory entry is unchanged: GPU stages deselect the file via-m "not cpu_only", and the CPU-stage collection hook picks it up via the module marker, following the existing CPU-only test migration pattern (#17290).Test Coverage
unittest/_torch/thop/parallel_hw_agnostic/test_custom_ops.pynow collected by the CPU-Generic stages (-m cpu_only); sibling GPU-dependent files in the directory remain H100-only.PR Checklist
Dev Engineer Review
tests/unittest/_torch/thop/parallel_hw_agnostic/test_custom_ops.pytotests/integration/test_lists/test-db/l0_cpu.yml.pytest.mark.cpu_only.Verdict: sufficient.
QA Engineer Review
tests/unittest/_torch/thop/parallel_hw_agnostic/test_custom_ops.py.tests/integration/test_lists/test-db/l0_cpu.yml.Verdict: sufficient.