ci: build sgl-kernel wheels for both cu129 and cu130 (#23497)
This commit is contained in:
@@ -117,7 +117,7 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
path: sgl-kernel/dist/
|
path: sgl-kernel/dist/
|
||||||
merge-multiple: true
|
merge-multiple: true
|
||||||
pattern: wheel-python3.10-cuda13.0
|
pattern: wheel-python3.10-cuda*
|
||||||
|
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
timeout-minutes: 20
|
timeout-minutes: 20
|
||||||
@@ -186,7 +186,7 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
path: sgl-kernel/dist/
|
path: sgl-kernel/dist/
|
||||||
merge-multiple: true
|
merge-multiple: true
|
||||||
pattern: wheel-python3.10-cuda13.0
|
pattern: wheel-python3.10-cuda*
|
||||||
|
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
timeout-minutes: 20
|
timeout-minutes: 20
|
||||||
@@ -251,7 +251,7 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
path: sgl-kernel/dist/
|
path: sgl-kernel/dist/
|
||||||
merge-multiple: true
|
merge-multiple: true
|
||||||
pattern: wheel-python3.10-cuda13.0
|
pattern: wheel-python3.10-cuda*
|
||||||
|
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
timeout-minutes: 20
|
timeout-minutes: 20
|
||||||
@@ -300,7 +300,7 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
path: sgl-kernel/dist/
|
path: sgl-kernel/dist/
|
||||||
merge-multiple: true
|
merge-multiple: true
|
||||||
pattern: wheel-python3.10-cuda13.0
|
pattern: wheel-python3.10-cuda*
|
||||||
|
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
timeout-minutes: 20
|
timeout-minutes: 20
|
||||||
@@ -356,7 +356,7 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
path: sgl-kernel/dist/
|
path: sgl-kernel/dist/
|
||||||
merge-multiple: true
|
merge-multiple: true
|
||||||
pattern: wheel-python3.10-cuda13.0
|
pattern: wheel-python3.10-cuda*
|
||||||
|
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
timeout-minutes: 20
|
timeout-minutes: 20
|
||||||
|
|||||||
@@ -53,7 +53,7 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
path: sgl-kernel/dist/
|
path: sgl-kernel/dist/
|
||||||
merge-multiple: true
|
merge-multiple: true
|
||||||
pattern: wheel-python3.10-cuda13.0
|
pattern: wheel-python3.10-cuda*
|
||||||
|
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
timeout-minutes: 20
|
timeout-minutes: 20
|
||||||
@@ -88,7 +88,7 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
path: sgl-kernel/dist/
|
path: sgl-kernel/dist/
|
||||||
merge-multiple: true
|
merge-multiple: true
|
||||||
pattern: wheel-python3.10-cuda13.0
|
pattern: wheel-python3.10-cuda*
|
||||||
|
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
timeout-minutes: 20
|
timeout-minutes: 20
|
||||||
@@ -123,7 +123,7 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
path: sgl-kernel/dist/
|
path: sgl-kernel/dist/
|
||||||
merge-multiple: true
|
merge-multiple: true
|
||||||
pattern: wheel-python3.10-cuda13.0
|
pattern: wheel-python3.10-cuda*
|
||||||
|
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
timeout-minutes: 20
|
timeout-minutes: 20
|
||||||
@@ -170,7 +170,7 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
path: sgl-kernel/dist/
|
path: sgl-kernel/dist/
|
||||||
merge-multiple: true
|
merge-multiple: true
|
||||||
pattern: wheel-python3.10-cuda13.0
|
pattern: wheel-python3.10-cuda*
|
||||||
|
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
timeout-minutes: 20
|
timeout-minutes: 20
|
||||||
@@ -201,7 +201,7 @@ jobs:
|
|||||||
# with:
|
# with:
|
||||||
# path: sgl-kernel/dist/
|
# path: sgl-kernel/dist/
|
||||||
# merge-multiple: true
|
# merge-multiple: true
|
||||||
# pattern: wheel-python3.10-cuda13.0
|
# pattern: wheel-python3.10-cuda*
|
||||||
|
|
||||||
# - name: Install dependencies
|
# - name: Install dependencies
|
||||||
# run: |
|
# run: |
|
||||||
|
|||||||
@@ -459,6 +459,8 @@ jobs:
|
|||||||
include:
|
include:
|
||||||
- python-version: "3.10"
|
- python-version: "3.10"
|
||||||
cuda-version: "13.0"
|
cuda-version: "13.0"
|
||||||
|
- python-version: "3.10"
|
||||||
|
cuda-version: "12.9"
|
||||||
name: Build Wheel
|
name: Build Wheel
|
||||||
steps:
|
steps:
|
||||||
- name: Cleanup
|
- name: Cleanup
|
||||||
@@ -519,6 +521,8 @@ jobs:
|
|||||||
include:
|
include:
|
||||||
- python-version: "3.10"
|
- python-version: "3.10"
|
||||||
cuda-version: "13.0"
|
cuda-version: "13.0"
|
||||||
|
- python-version: "3.10"
|
||||||
|
cuda-version: "12.9"
|
||||||
name: Build Wheel Arm
|
name: Build Wheel Arm
|
||||||
steps:
|
steps:
|
||||||
- name: Cleanup
|
- name: Cleanup
|
||||||
@@ -625,7 +629,7 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
path: sgl-kernel/dist/
|
path: sgl-kernel/dist/
|
||||||
merge-multiple: true
|
merge-multiple: true
|
||||||
pattern: wheel-python3.10-cuda13.0
|
pattern: wheel-python3.10-cuda*
|
||||||
|
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
timeout-minutes: 20
|
timeout-minutes: 20
|
||||||
@@ -748,7 +752,7 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
path: sgl-kernel/dist/
|
path: sgl-kernel/dist/
|
||||||
merge-multiple: true
|
merge-multiple: true
|
||||||
pattern: wheel-python3.10-cuda13.0
|
pattern: wheel-python3.10-cuda*
|
||||||
|
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
timeout-minutes: 20
|
timeout-minutes: 20
|
||||||
@@ -810,7 +814,7 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
path: sgl-kernel/dist/
|
path: sgl-kernel/dist/
|
||||||
merge-multiple: true
|
merge-multiple: true
|
||||||
pattern: wheel-python3.10-cuda13.0
|
pattern: wheel-python3.10-cuda*
|
||||||
|
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
timeout-minutes: 20
|
timeout-minutes: 20
|
||||||
@@ -869,7 +873,7 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
path: sgl-kernel/dist/
|
path: sgl-kernel/dist/
|
||||||
merge-multiple: true
|
merge-multiple: true
|
||||||
pattern: wheel-python3.10-cuda13.0
|
pattern: wheel-python3.10-cuda*
|
||||||
|
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
timeout-minutes: 20
|
timeout-minutes: 20
|
||||||
@@ -929,7 +933,7 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
path: sgl-kernel/dist/
|
path: sgl-kernel/dist/
|
||||||
merge-multiple: true
|
merge-multiple: true
|
||||||
pattern: wheel-python3.10-cuda13.0
|
pattern: wheel-python3.10-cuda*
|
||||||
|
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
timeout-minutes: 20
|
timeout-minutes: 20
|
||||||
@@ -1023,7 +1027,7 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
path: sgl-kernel/dist/
|
path: sgl-kernel/dist/
|
||||||
merge-multiple: true
|
merge-multiple: true
|
||||||
pattern: wheel-python3.10-cuda13.0
|
pattern: wheel-python3.10-cuda*
|
||||||
|
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
timeout-minutes: 20
|
timeout-minutes: 20
|
||||||
@@ -1081,7 +1085,7 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
path: sgl-kernel/dist/
|
path: sgl-kernel/dist/
|
||||||
merge-multiple: true
|
merge-multiple: true
|
||||||
pattern: wheel-python3.10-cuda13.0
|
pattern: wheel-python3.10-cuda*
|
||||||
|
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
timeout-minutes: 20
|
timeout-minutes: 20
|
||||||
@@ -1161,7 +1165,7 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
path: sgl-kernel/dist/
|
path: sgl-kernel/dist/
|
||||||
merge-multiple: true
|
merge-multiple: true
|
||||||
pattern: wheel-python3.10-cuda13.0
|
pattern: wheel-python3.10-cuda*
|
||||||
|
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
timeout-minutes: 20
|
timeout-minutes: 20
|
||||||
@@ -1215,7 +1219,7 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
path: sgl-kernel/dist/
|
path: sgl-kernel/dist/
|
||||||
merge-multiple: true
|
merge-multiple: true
|
||||||
pattern: wheel-python3.10-cuda13.0
|
pattern: wheel-python3.10-cuda*
|
||||||
|
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
timeout-minutes: 20
|
timeout-minutes: 20
|
||||||
@@ -1284,7 +1288,7 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
path: sgl-kernel/dist/
|
path: sgl-kernel/dist/
|
||||||
merge-multiple: true
|
merge-multiple: true
|
||||||
pattern: wheel-python3.10-cuda13.0
|
pattern: wheel-python3.10-cuda*
|
||||||
|
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
timeout-minutes: 20
|
timeout-minutes: 20
|
||||||
@@ -1359,7 +1363,7 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
path: sgl-kernel/dist/
|
path: sgl-kernel/dist/
|
||||||
merge-multiple: true
|
merge-multiple: true
|
||||||
pattern: wheel-python3.10-cuda13.0
|
pattern: wheel-python3.10-cuda*
|
||||||
|
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
timeout-minutes: 20
|
timeout-minutes: 20
|
||||||
@@ -1421,7 +1425,7 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
path: sgl-kernel/dist/
|
path: sgl-kernel/dist/
|
||||||
merge-multiple: true
|
merge-multiple: true
|
||||||
pattern: wheel-python3.10-cuda13.0
|
pattern: wheel-python3.10-cuda*
|
||||||
|
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
timeout-minutes: 20
|
timeout-minutes: 20
|
||||||
|
|||||||
@@ -314,10 +314,23 @@ if [ "${CUSTOM_BUILD_SGL_KERNEL:-}" = "true" ] && [ -d "sgl-kernel/dist" ]; then
|
|||||||
else
|
else
|
||||||
WHEEL_ARCH="x86_64"
|
WHEEL_ARCH="x86_64"
|
||||||
fi
|
fi
|
||||||
# Wheel may have +cuXYZ suffix (e.g. sglang_kernel-0.4.0+cu130-...) depending on CUDA version
|
# Wheel filenames carry a +cuXYZ local version tag (e.g. sglang_kernel-0.4.0+cu130-...).
|
||||||
KERNEL_WHL=$(ls sgl-kernel/dist/sglang_kernel-${SGL_KERNEL_VERSION_FROM_KERNEL}*-cp310-abi3-manylinux2014_${WHEEL_ARCH}.whl 2>/dev/null | head -1)
|
# When the build matrix produces wheels for multiple CUDA versions (e.g. both cu129 and cu130),
|
||||||
|
# pick the one matching the test runner's $CU_VERSION so we don't trigger the PyPI-fallback reinstall
|
||||||
|
# below (which would replace the PR-built wheel with a public main-branch wheel).
|
||||||
|
KERNEL_WHL=$(ls sgl-kernel/dist/sglang_kernel-${SGL_KERNEL_VERSION_FROM_KERNEL}+${CU_VERSION}-cp310-abi3-manylinux2014_${WHEEL_ARCH}.whl 2>/dev/null | head -1)
|
||||||
if [ -z "$KERNEL_WHL" ]; then
|
if [ -z "$KERNEL_WHL" ]; then
|
||||||
echo "ERROR: No matching sgl-kernel wheel found in sgl-kernel/dist/ for version ${SGL_KERNEL_VERSION_FROM_KERNEL} arch ${WHEEL_ARCH}"
|
# Fallback for older branches that only build a single CUDA variant and whose wheel matches
|
||||||
|
# the current $CU_VERSION. Restrict to the same arch — we intentionally do NOT match a wheel
|
||||||
|
# whose +cuXYZ tag disagrees with $CU_VERSION here, because the post-install reinstall branch
|
||||||
|
# below would otherwise silently replace it with the public main-branch wheel.
|
||||||
|
SINGLE_CUDA_WHL=$(ls sgl-kernel/dist/sglang_kernel-${SGL_KERNEL_VERSION_FROM_KERNEL}-cp310-abi3-manylinux2014_${WHEEL_ARCH}.whl 2>/dev/null | head -1)
|
||||||
|
if [ -n "$SINGLE_CUDA_WHL" ]; then
|
||||||
|
KERNEL_WHL="$SINGLE_CUDA_WHL"
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
if [ -z "$KERNEL_WHL" ]; then
|
||||||
|
echo "ERROR: No matching sgl-kernel wheel found in sgl-kernel/dist/ for version ${SGL_KERNEL_VERSION_FROM_KERNEL} arch ${WHEEL_ARCH} cuda ${CU_VERSION}"
|
||||||
ls -alh sgl-kernel/dist/
|
ls -alh sgl-kernel/dist/
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|||||||
Reference in New Issue
Block a user