|
99 | 99 | needs: [check-changes, sgl-kernel-build-wheels]
|
100 | 100 | if: needs.check-changes.outputs.sgl_kernel == 'true'
|
101 | 101 | runs-on: 1-gpu-runner
|
102 |
| - env: |
103 |
| - HF_TOKEN: ${{ secrets.HF_TOKEN }} |
104 | 102 | steps:
|
105 | 103 | - uses: actions/checkout@v4
|
106 | 104 |
|
@@ -155,6 +153,50 @@ jobs:
|
155 | 153 | cd test/srt
|
156 | 154 | python3 test_mla_deepseek_v3.py
|
157 | 155 |
|
| 156 | + sgl-kernel-benchmark-test: |
| 157 | + needs: [check-changes, sgl-kernel-build-wheels] |
| 158 | + if: always() && !failure() && !cancelled() |
| 159 | + runs-on: 1-gpu-runner |
| 160 | + env: |
| 161 | + HF_TOKEN: ${{ secrets.HF_TOKEN }} |
| 162 | + CI: true |
| 163 | + steps: |
| 164 | + - uses: actions/checkout@v4 |
| 165 | + |
| 166 | + - name: Cleanup |
| 167 | + run: | |
| 168 | + ls -alh sgl-kernel/dist || true |
| 169 | + rm -rf sgl-kernel/dist/* || true |
| 170 | +
|
| 171 | + - name: Download artifacts |
| 172 | + uses: actions/download-artifact@v4 |
| 173 | + with: |
| 174 | + path: sgl-kernel/dist/ |
| 175 | + merge-multiple: true |
| 176 | + pattern: wheel-python3.10-cuda12.9 |
| 177 | + |
| 178 | + - name: Install dependencies |
| 179 | + run: | |
| 180 | + CUSTOM_BUILD_SGL_KERNEL=${{needs.check-changes.outputs.sgl_kernel}} bash scripts/ci/ci_install_dependency.sh |
| 181 | +
|
| 182 | + - name: Run benchmark tests |
| 183 | + timeout-minutes: 45 |
| 184 | + run: | |
| 185 | + cd sgl-kernel/benchmark |
| 186 | + echo "Running sgl-kernel benchmark tests in CI mode..." |
| 187 | +
|
| 188 | + echo "CI environment variable: $CI" |
| 189 | + echo "GITHUB_ACTIONS environment variable: $GITHUB_ACTIONS" |
| 190 | +
|
| 191 | + for bench_file in bench_*.py; do |
| 192 | + echo "Testing $bench_file..." |
| 193 | + timeout 60 python3 "$bench_file" || echo "Warning: $bench_file timed out or failed, continuing..." |
| 194 | + echo "Completed $bench_file" |
| 195 | + echo "---" |
| 196 | + done |
| 197 | +
|
| 198 | + echo "All benchmark tests completed!" |
| 199 | +
|
158 | 200 | # =============================================== primary ====================================================
|
159 | 201 |
|
160 | 202 | unit-test-frontend:
|
@@ -189,8 +231,6 @@ jobs:
|
189 | 231 | if: always() && !failure() && !cancelled() &&
|
190 | 232 | ((needs.check-changes.outputs.main_package == 'true') || (needs.check-changes.outputs.sgl_kernel == 'true'))
|
191 | 233 | runs-on: 1-gpu-runner
|
192 |
| - env: |
193 |
| - HF_TOKEN: ${{ secrets.HF_TOKEN }} |
194 | 234 | strategy:
|
195 | 235 | fail-fast: false
|
196 | 236 | matrix:
|
@@ -222,8 +262,6 @@ jobs:
|
222 | 262 | if: always() && !failure() && !cancelled() &&
|
223 | 263 | ((needs.check-changes.outputs.main_package == 'true') || (needs.check-changes.outputs.sgl_kernel == 'true'))
|
224 | 264 | runs-on: 2-gpu-runner
|
225 |
| - env: |
226 |
| - HF_TOKEN: ${{ secrets.HF_TOKEN }} |
227 | 265 | strategy:
|
228 | 266 | fail-fast: false
|
229 | 267 | matrix:
|
@@ -255,8 +293,6 @@ jobs:
|
255 | 293 | if: always() && !failure() && !cancelled() &&
|
256 | 294 | ((needs.check-changes.outputs.main_package == 'true') || (needs.check-changes.outputs.sgl_kernel == 'true'))
|
257 | 295 | runs-on: 4-gpu-runner
|
258 |
| - env: |
259 |
| - HF_TOKEN: ${{ secrets.HF_TOKEN }} |
260 | 296 | strategy:
|
261 | 297 | fail-fast: false
|
262 | 298 | matrix:
|
@@ -288,8 +324,6 @@ jobs:
|
288 | 324 | if: always() && !failure() && !cancelled() &&
|
289 | 325 | ((needs.check-changes.outputs.main_package == 'true') || (needs.check-changes.outputs.sgl_kernel == 'true'))
|
290 | 326 | runs-on: 8-gpu-runner
|
291 |
| - env: |
292 |
| - HF_TOKEN: ${{ secrets.HF_TOKEN }} |
293 | 327 | strategy:
|
294 | 328 | fail-fast: false
|
295 | 329 | matrix:
|
@@ -321,8 +355,6 @@ jobs:
|
321 | 355 | if: always() && !failure() && !cancelled() &&
|
322 | 356 | ((needs.check-changes.outputs.main_package == 'true') || (needs.check-changes.outputs.sgl_kernel == 'true'))
|
323 | 357 | runs-on: 1-gpu-runner
|
324 |
| - env: |
325 |
| - HF_TOKEN: ${{ secrets.HF_TOKEN }} |
326 | 358 | steps:
|
327 | 359 | - name: Checkout code
|
328 | 360 | uses: actions/checkout@v4
|
@@ -382,8 +414,6 @@ jobs:
|
382 | 414 | if: always() && !failure() && !cancelled() &&
|
383 | 415 | ((needs.check-changes.outputs.main_package == 'true') || (needs.check-changes.outputs.sgl_kernel == 'true'))
|
384 | 416 | runs-on: 1-gpu-runner
|
385 |
| - env: |
386 |
| - HF_TOKEN: ${{ secrets.HF_TOKEN }} |
387 | 417 | steps:
|
388 | 418 | - name: Checkout code
|
389 | 419 | uses: actions/checkout@v4
|
@@ -435,8 +465,6 @@ jobs:
|
435 | 465 | if: always() && !failure() && !cancelled() &&
|
436 | 466 | ((needs.check-changes.outputs.main_package == 'true') || (needs.check-changes.outputs.sgl_kernel == 'true'))
|
437 | 467 | runs-on: 2-gpu-runner
|
438 |
| - env: |
439 |
| - HF_TOKEN: ${{ secrets.HF_TOKEN }} |
440 | 468 | steps:
|
441 | 469 | - name: Checkout code
|
442 | 470 | uses: actions/checkout@v4
|
@@ -494,8 +522,6 @@ jobs:
|
494 | 522 | if: always() && !failure() && !cancelled() &&
|
495 | 523 | ((needs.check-changes.outputs.main_package == 'true') || (needs.check-changes.outputs.sgl_kernel == 'true'))
|
496 | 524 | runs-on: 1-gpu-runner
|
497 |
| - env: |
498 |
| - HF_TOKEN: ${{ secrets.HF_TOKEN }} |
499 | 525 | steps:
|
500 | 526 | - name: Checkout code
|
501 | 527 | uses: actions/checkout@v4
|
@@ -526,8 +552,6 @@ jobs:
|
526 | 552 | if: always() && !failure() && !cancelled() &&
|
527 | 553 | ((needs.check-changes.outputs.main_package == 'true') || (needs.check-changes.outputs.sgl_kernel == 'true'))
|
528 | 554 | runs-on: 2-gpu-runner
|
529 |
| - env: |
530 |
| - HF_TOKEN: ${{ secrets.HF_TOKEN }} |
531 | 555 | steps:
|
532 | 556 | - name: Checkout code
|
533 | 557 | uses: actions/checkout@v4
|
@@ -558,8 +582,6 @@ jobs:
|
558 | 582 | if: always() && !failure() && !cancelled() &&
|
559 | 583 | ((needs.check-changes.outputs.main_package == 'true') || (needs.check-changes.outputs.sgl_kernel == 'true'))
|
560 | 584 | runs-on: 4-gpu-runner
|
561 |
| - env: |
562 |
| - HF_TOKEN: ${{ secrets.HF_TOKEN }} |
563 | 585 | steps:
|
564 | 586 | - name: Checkout code
|
565 | 587 | uses: actions/checkout@v4
|
@@ -587,8 +609,6 @@ jobs:
|
587 | 609 | if: always() && !failure() && !cancelled() &&
|
588 | 610 | ((needs.check-changes.outputs.main_package == 'true') || (needs.check-changes.outputs.sgl_kernel == 'true'))
|
589 | 611 | runs-on: 8-gpu-runner
|
590 |
| - env: |
591 |
| - HF_TOKEN: ${{ secrets.HF_TOKEN }} |
592 | 612 | steps:
|
593 | 613 | - name: Checkout code
|
594 | 614 | uses: actions/checkout@v4
|
@@ -616,8 +636,6 @@ jobs:
|
616 | 636 | if: always() && !failure() && !cancelled() &&
|
617 | 637 | ((needs.check-changes.outputs.main_package == 'true') || (needs.check-changes.outputs.sgl_kernel == 'true'))
|
618 | 638 | runs-on: 4-b200-runner
|
619 |
| - env: |
620 |
| - HF_TOKEN: ${{ secrets.HF_TOKEN }} |
621 | 639 | strategy:
|
622 | 640 | fail-fast: false
|
623 | 641 | steps:
|
@@ -647,7 +665,7 @@ jobs:
|
647 | 665 | check-changes,
|
648 | 666 |
|
649 | 667 | sgl-kernel-build-wheels,
|
650 |
| - sgl-kernel-unit-test, sgl-kernel-mla-test, |
| 668 | + sgl-kernel-unit-test, sgl-kernel-mla-test, sgl-kernel-benchmark-test, |
651 | 669 |
|
652 | 670 | unit-test-frontend, unit-test-backend-1-gpu,
|
653 | 671 | unit-test-backend-2-gpu, unit-test-backend-4-gpu, unit-test-backend-8-gpu,
|
|
0 commit comments