Skip to content

[CI] Move misplaced mhc kernel test into test/registered/kernels - #27781

Merged
hnyls2002 merged 2 commits into
sgl-project:mainfrom
DarkSharpness:chore/move-mhc-kernel-test
Jun 10, 2026
Merged

hnyls2002 merged 2 commits into
sgl-project:mainfrom
DarkSharpness:chore/move-mhc-kernel-test

Conversation

@DarkSharpness

@DarkSharpness DarkSharpness commented Jun 10, 2026

Copy link
Copy Markdown
Collaborator

Motivation

tests/kernels/test_mhc_kernels.py (added in #25976) is the only file under a stray top-level tests/ directory, which sits outside the repo's test/ tree. Because the CI runner only scans test/registered/ (and the JIT kernel dirs), this test was never discovered or executed.

Modifications

  • Move the file to test/registered/kernels/test_mhc_kernels.py, alongside the other kernel correctness tests.
  • Add the required module-level register_cuda_ci(est_time=30, stage="base-b", runner_config="1-gpu-small") so run_suite.py discovers it (small memory footprint; requires CUDA + TileLang).
  • Add the standard pytest __main__ footer per test/README.md.
  • Remove the now-empty top-level tests/ directory.

The test body itself is unchanged — this is a pure relocation + CI wiring fix.

Checklist

  • Verified the imported symbols (mhc_pre, mhc_post, mhc_fused_post_pre, is_dsa_prefill_cp_round_robin_split) still exist in sglang.srt.layers.mhc
  • Confirmed the registration is AST-discoverable (literal est_time/stage/runner_config)
  • Matches the registration + footer pattern of existing test/registered/kernels/ tests

🤖 Generated with Claude Code


CI States

Latest PR Test (Base): ❌ Run #27263719495
Latest PR Test (Extra): ❌ Run #27263718691

`tests/kernels/test_mhc_kernels.py` (added in sgl-project#25976) was the only file under
a stray top-level `tests/` directory, outside the repo's `test/` tree, so it was
never discovered by the CI runner.

- Move it to `test/registered/kernels/test_mhc_kernels.py`, alongside the other
  kernel correctness tests.
- Add the required module-level `register_cuda_ci(...)` so `run_suite.py` picks
  it up (base-b, 1-gpu-small; small footprint, CUDA + TileLang).
- Add the standard pytest `__main__` footer per test/README.md.
- Remove the now-empty top-level `tests/` directory.

Test body is unchanged.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Code Review

This pull request registers the MHC kernels test file for CUDA CI by importing and calling register_cuda_ci with specific configurations. Additionally, it adds a standard main block to allow running the test file directly using pytest. There are no review comments, so I have no feedback to provide.

Important

The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.

@DarkSharpness

Copy link
Copy Markdown
Collaborator Author

/rerun-test test/registered/kernels/test_mhc_kernels.py

@github-actions

github-actions Bot commented Jun 10, 2026

Copy link
Copy Markdown
Contributor

Results for /rerun-test test/registered/kernels/test_mhc_kernels.py:

🚀 1-gpu-5090 (1 test): ❌ View workflow run

cd test/ && python3 registered/kernels/test_mhc_kernels.py

The mHC kernels route their TF32 prenorm GEMM through DeepGEMM, which is
disabled on the 1-gpu-small (RTX 5090 / SM120) pool — `_compute_enable_deep_gemm`
returns False for SM120, so `deep_gemm` is never imported and the test hits
`NameError: name 'deep_gemm' is not defined`. Register on 1-gpu-large (H100 /
SM90), matching the other DeepGEMM-dependent kernel tests.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@DarkSharpness

Copy link
Copy Markdown
Collaborator Author

/rerun-test test/registered/kernels/test_mhc_kernels.py

@github-actions

github-actions Bot commented Jun 10, 2026

Copy link
Copy Markdown
Contributor

Results for /rerun-test test/registered/kernels/test_mhc_kernels.py:

🚀 1-gpu-h100 (1 test): ✅ View workflow run

cd test/ && python3 registered/kernels/test_mhc_kernels.py

@hnyls2002
hnyls2002 merged commit b40f365 into sgl-project:main Jun 10, 2026
89 of 98 checks passed
Chronostasys pushed a commit to MindLab-Research/sglang that referenced this pull request Aug 24, 2026
jakki-amd pushed a commit to jakki-amd/sglang that referenced this pull request Sep 9, 2026
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.

3 participants