[CI] Tiny refactoring sgl-kernel tests (#13813)

This commit is contained in:
Baizhou Zhang
2025-11-23 12:45:17 -08:00
committed by GitHub
parent 618ca23802
commit c9bd1aca32
2 changed files with 55 additions and 70 deletions
+55 -27
View File
@@ -256,36 +256,37 @@ jobs:
echo "All benchmark tests completed!" echo "All benchmark tests completed!"
sgl-kernel-b200-test: # sgl-kernel-b200-test:
needs: [check-changes, sgl-kernel-build-wheels] # needs: [check-changes, sgl-kernel-build-wheels]
if: needs.check-changes.outputs.sgl_kernel == 'true' # if: needs.check-changes.outputs.sgl_kernel == 'true'
runs-on: 4-gpu-b200 # runs-on: 4-gpu-b200
env: # env:
RUNNER_LABELS: 4-gpu-b200 # RUNNER_LABELS: 4-gpu-b200
steps: # steps:
- uses: actions/checkout@v4 # - uses: actions/checkout@v4
- name: Cleanup # - name: Cleanup
run: | # run: |
ls -alh sgl-kernel/dist || true # ls -alh sgl-kernel/dist || true
rm -rf sgl-kernel/dist/* || true # rm -rf sgl-kernel/dist/* || true
- name: Download artifacts # - name: Download artifacts
uses: actions/download-artifact@v4 # uses: actions/download-artifact@v4
with: # with:
path: sgl-kernel/dist/ # path: sgl-kernel/dist/
merge-multiple: true # merge-multiple: true
pattern: wheel-python3.10-cuda12.9 # pattern: wheel-python3.10-cuda12.9
- name: Install dependencies # - name: Install dependencies
run: | # run: |
CUSTOM_BUILD_SGL_KERNEL=${{needs.check-changes.outputs.sgl_kernel}} IS_BLACKWELL=1 bash scripts/ci/ci_install_dependency.sh # CUSTOM_BUILD_SGL_KERNEL=${{needs.check-changes.outputs.sgl_kernel}} IS_BLACKWELL=1 bash scripts/ci/ci_install_dependency.sh
# - name: Run sgl-kernel unit tests on B200
# timeout-minutes: 30
# run: |
# cd sgl-kernel
# pytest tests/
- name: Run sgl-kernel unit tests on B200
timeout-minutes: 30
run: |
cd sgl-kernel
pytest tests/
# Adding a single CUDA13 smoke test to verify that the kernel builds and runs # Adding a single CUDA13 smoke test to verify that the kernel builds and runs
# TODO: Add back this test when it can pass on CI # TODO: Add back this test when it can pass on CI
# cuda13-kernel-smoke-test: # cuda13-kernel-smoke-test:
@@ -404,6 +405,33 @@ jobs:
--partition-id ${{ matrix.part }} \ --partition-id ${{ matrix.part }} \
--total-partitions 2 --total-partitions 2
quantization-test:
needs: [check-changes, stage-a-test-1]
if: always() && !failure() && !cancelled() &&
((needs.check-changes.outputs.main_package == 'true') || (needs.check-changes.outputs.sgl_kernel == 'true'))
runs-on: 1-gpu-runner
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Download artifacts
if: needs.check-changes.outputs.sgl_kernel == 'true'
uses: actions/download-artifact@v4
with:
path: sgl-kernel/dist/
merge-multiple: true
pattern: wheel-python3.10-cuda12.9
- name: Install dependencies
run: |
CUSTOM_BUILD_SGL_KERNEL=${{needs.check-changes.outputs.sgl_kernel}} bash scripts/ci/ci_install_dependency.sh
pip install "bitsandbytes>=0.44.0"
- name: Run test
timeout-minutes: 30
run: |
cd test/srt
python3 run_suite.py --suite quantization_test
unit-test-backend-1-gpu: unit-test-backend-1-gpu:
needs: [check-changes, stage-a-test-1] needs: [check-changes, stage-a-test-1]
if: always() && !failure() && !cancelled() && if: always() && !failure() && !cancelled() &&
@@ -988,12 +1016,12 @@ jobs:
sgl-kernel-unit-test, sgl-kernel-unit-test,
sgl-kernel-mla-test, sgl-kernel-mla-test,
sgl-kernel-benchmark-test, sgl-kernel-benchmark-test,
sgl-kernel-b200-test,
multimodal-gen-test-1-gpu, multimodal-gen-test-1-gpu,
multimodal-gen-test-2-gpu, multimodal-gen-test-2-gpu,
stage-a-test-1, stage-a-test-1,
quantization-test,
unit-test-backend-1-gpu, unit-test-backend-1-gpu,
unit-test-backend-2-gpu, unit-test-backend-2-gpu,
unit-test-backend-4-gpu, unit-test-backend-4-gpu,
-43
View File
@@ -1,43 +0,0 @@
name: Quantization Test
on:
push:
branches: [ main ]
paths:
- "python/**"
- "!python/sglang/multimodal_gen/**"
- "scripts/ci/**"
- "test/**"
- ".github/workflows/quantization-test.yml"
pull_request:
branches: [ main ]
paths:
- "python/**"
- "!python/sglang/multimodal_gen/**"
- "scripts/ci/**"
- "test/**"
- ".github/workflows/quantization-test.yml"
workflow_dispatch:
concurrency:
group: quantization-test-${{ github.ref }}
cancel-in-progress: true
jobs:
quantization-test:
if: github.event_name != 'pull_request' || contains(github.event.pull_request.labels.*.name, 'run-ci')
runs-on: 1-gpu-runner
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Install dependencies
run: |
bash scripts/ci/ci_install_dependency.sh
pip install "bitsandbytes>=0.44.0"
- name: Run Quantization tests
timeout-minutes: 30
run: |
cd test/srt
python3 run_suite.py --suite quantization_test