[XPU] upgrade to torch 2.13 (#48677)
Signed-off-by: Yan Ma <yan.ma@intel.com> Signed-off-by: Kunshang Ji <kunshang.ji@intel.com> Co-authored-by: Kunshang Ji <kunshang.ji@intel.com> Co-authored-by: Cyrus Leung <tlleungac@connect.ust.hk>
Yan Ma committed
Jul 29, 2026 at 16:24 UTC
5b29c958c713d367c7caf9313529d4fb2dd6b762
7 files changed
+35
-92
.buildkite/scripts/hardware_ci/run-intel-test.sh
+1
-1
@@ -369,7 +369,7 @@ export HF_TOKEN ZE_AFFINITY_MASK
369
-e CMDS \
370
--name "${container_name}" \
371
"${IMAGE}" \
372
- bash -c 'set -e; source /opt/intel/oneapi/setvars.sh --force; source /opt/intel/oneapi/ccl/2021.15/env/vars.sh --force; echo "ZE_AFFINITY_MASK is ${ZE_AFFINITY_MASK:-}"; eval "$CMDS"' \
372
+ bash -c 'set -e; echo "ZE_AFFINITY_MASK is ${ZE_AFFINITY_MASK:-}"; eval "$CMDS"' \
373
>/dev/null
374
} 9>/tmp/docker-pull.lock
375
docker/Dockerfile.xpu
+2
-35
@@ -63,21 +63,6 @@ RUN apt-get update -y && \
63
python3-pip && \
64
rm -rf /var/lib/apt/lists/*
65
66
-# Add oneAPI repo, pin oneAPI to 2025.3, then install pinned packages in one layer.
67
-RUN wget -O- https://apt.repos.intel.com/intel-gpg-keys/GPG-PUB-KEY-INTEL-SW-PRODUCTS.PUB | gpg --dearmor | tee /usr/share/keyrings/oneapi-archive-keyring.gpg > /dev/null && \
68
- echo "deb [signed-by=/usr/share/keyrings/oneapi-archive-keyring.gpg] https://apt.repos.intel.com/oneapi all main" | tee /etc/apt/sources.list.d/oneAPI.list && \
69
- printf '%s\n' \
70
- 'Package: intel-oneapi-* intel-deep-learning-essentials* intel-pti*' \
71
- 'Pin: version 2025.3*' \
72
- 'Pin-Priority: 1001' \
73
- > /etc/apt/preferences.d/oneapi-2025.3.pref && \
74
- apt-get update -y && \
75
- apt-get install -y --no-install-recommends \
76
- intel-oneapi-compiler-dpcpp-cpp-2025.3 \
77
- intel-oneapi-mkl-devel-2025.3 \
78
- intel-oneapi-dnnl-devel-2025.3 && \
79
- rm -rf /var/lib/apt/lists/*
80
-
66
# Install UMD
67
RUN mkdir neo && \
68
cd neo && \
@@ -100,22 +85,6 @@ RUN curl -LsSf https://astral.sh/uv/install.sh | sh \
85
&& uv venv --python ${PYTHON_VERSION} --seed ${VIRTUAL_ENV}
86
ENV PATH="$VIRTUAL_ENV/bin:$PATH"
87
103
-# This oneccl contains the BMG support which is not the case for default version of oneapi 2025.3.
104
-ARG ONECCL_INSTALLER="intel-oneccl-2021.15.9.14_offline.sh"
105
-RUN wget "https://github.com/uxlfoundation/oneCCL/releases/download/2021.15.9/${ONECCL_INSTALLER}" && \
106
- bash "${ONECCL_INSTALLER}" -a --silent --eula accept && \
107
- rm "${ONECCL_INSTALLER}" && \
108
- echo "source /opt/intel/oneapi/setvars.sh --force" >> /root/.bashrc && \
109
- echo "source /opt/intel/oneapi/ccl/2021.15/env/vars.sh --force" >> /root/.bashrc && \
110
- rm -f /opt/intel/oneapi/ccl/latest && \
111
- ln -s /opt/intel/oneapi/ccl/2021.15 /opt/intel/oneapi/ccl/latest && \
112
- printf '%s\n' \
113
- '/opt/intel/oneapi/ccl/2021.15/lib' \
114
- '/opt/intel/oneapi/mpi/2021.15/lib' \
115
- '/opt/intel/oneapi/compiler/2025.3/lib' \
116
- > /etc/ld.so.conf.d/oneapi-ccl.conf && \
117
- ldconfig
118
-
88
SHELL ["bash", "-c"]
89
CMD ["bash", "-c", "source /root/.bashrc && exec bash"]
90
@@ -135,8 +104,7 @@ RUN --mount=type=cache,target=/root/.cache/uv \
104
uv pip install --upgrade pip
105
106
138
-
139
-ENV LD_LIBRARY_PATH=/opt/intel/oneapi/ccl/2021.15/lib:/opt/intel/oneapi/mpi/2021.15/lib:/opt/intel/oneapi/compiler/2025.3/lib:/usr/local/lib
107
+ENV LD_LIBRARY_PATH=/opt/venv/lib:/usr/local/lib
108
CMD ["/bin/bash"]
109
110
######################### UCX + NIXL BUILD STAGE #########################
@@ -216,8 +184,7 @@ RUN --mount=type=cache,target=/root/.cache/uv \
184
uv pip install -r /workspace/vllm/requirements/xpu.txt && \
185
uv pip install --no-build-isolation -r /workspace/vllm/requirements/test/xpu.txt && \
186
uv pip uninstall triton triton-xpu && \
219
- uv pip install triton-xpu==3.7.1 && \
220
- uv pip uninstall oneccl oneccl-devel
187
+ uv pip install triton-xpu==3.7.2
188
189
# Keep source-dependent layers near the end so frequent code-only changes
190
# don't invalidate heavy dependency and UCX/NIXL layers.
docs/getting_started/installation/gpu.xpu.inc.md
+2
-2
@@ -42,12 +42,12 @@ pip install -v -r requirements/xpu.txt
42
43
```bash
44
pip uninstall -y triton triton-xpu
45
- pip install triton-xpu==3.7.1 --extra-index-url https://download.pytorch.org/whl/xpu
45
+ pip install triton-xpu==3.7.2 --extra-index-url https://download.pytorch.org/whl/xpu
46
```
47
48
!!! note
49
- `triton` (without suffix) is for NVIDIA GPUs only. On XPU, using it instead of `triton-xpu` can cause correctness or runtime issues.
50
- - For torch 2.12 (the version used in `requirements/xpu.txt`), the matching package is `triton-xpu==3.7.1`. If you use a different version of torch, check the corresponding `triton-xpu` version in [docker/Dockerfile.xpu](https://github.com/vllm-project/vllm/blob/main/docker/Dockerfile.xpu).
50
+ - For torch 2.13 (the version used in `requirements/xpu.txt`), the matching package is `triton-xpu==3.7.2`. If you use a different version of torch, check the corresponding `triton-xpu` version in [docker/Dockerfile.xpu](https://github.com/vllm-project/vllm/blob/main/docker/Dockerfile.xpu).
51
52
- Finally, build and install vLLM XPU backend:
53
requirements/test/xpu.txt
+26
-24
@@ -140,7 +140,7 @@ docopt==0.6.2
140
# via num2words
141
docstring-parser==0.18.0
142
# via anthropic
143
-dpcpp-cpp-rt==2025.3.2
143
+dpcpp-cpp-rt==2026.0.0
144
# via
145
# onemkl-sycl-blas
146
# onemkl-sycl-dft
@@ -253,27 +253,27 @@ ijson==3.5.0
253
# via -r requirements/test/../common.txt
254
imageio==2.37.3
255
# via scikit-image
256
-impi-rt==2021.17.2
256
+impi-rt==2021.18.0
257
# via
258
# oneccl
259
# torch
260
iniconfig==2.3.0
261
# via pytest
262
-intel-cmplr-lib-rt==2025.3.2
262
+intel-cmplr-lib-rt==2026.0.0
263
# via
264
# intel-sycl-rt
265
# torch
266
-intel-cmplr-lib-ur==2025.3.2
266
+intel-cmplr-lib-ur==2026.0.0
267
# via
268
# intel-openmp
269
# intel-sycl-rt
270
# torch
271
-intel-cmplr-lic-rt==2025.3.2
271
+intel-cmplr-lic-rt==2026.0.0
272
# via
273
# intel-opencl-rt
274
# intel-sycl-rt
275
# torch
276
-intel-opencl-rt==2025.3.2
276
+intel-opencl-rt==2026.0.0
277
# via
278
# dpcpp-cpp-rt
279
# onemkl-sycl-blas
@@ -282,14 +282,14 @@ intel-opencl-rt==2025.3.2
282
# onemkl-sycl-rng
283
# onemkl-sycl-sparse
284
# torch
285
-intel-openmp==2025.3.2
285
+intel-openmp==2026.0.0
286
# via
287
# dpcpp-cpp-rt
288
# mkl
289
# torch
290
-intel-pti==0.16.0
290
+intel-pti==0.17.0
291
# via torch
292
-intel-sycl-rt==2025.3.2
292
+intel-sycl-rt==2026.0.0
293
# via
294
# dpcpp-cpp-rt
295
# oneccl
@@ -378,7 +378,7 @@ mistral-common==1.11.5
378
# -c requirements/common.txt
379
# -r requirements/test/../common.txt
380
# -r requirements/test/xpu.in
381
-mkl==2025.3.1
381
+mkl==2026.0.0
382
# via
383
# onemkl-sycl-blas
384
# onemkl-sycl-dft
@@ -453,28 +453,28 @@ numpy==2.2.6
453
# torchvision
454
# transformers
455
# xgrammar
456
-oneccl==2021.17.2
456
+oneccl==2022.0.0
457
# via
458
# oneccl-devel
459
# torch
460
-oneccl-devel==2021.17.2
460
+oneccl-devel==2022.0.0
461
# via torch
462
-onemkl-license==2025.3.1
462
+onemkl-license==2026.0.0
463
# via
464
# mkl
465
# torch
466
-onemkl-sycl-blas==2025.3.1
466
+onemkl-sycl-blas==2026.0.0
467
# via
468
# onemkl-sycl-lapack
469
# onemkl-sycl-sparse
470
# torch
471
-onemkl-sycl-dft==2025.3.1
471
+onemkl-sycl-dft==2026.0.0
472
# via torch
473
-onemkl-sycl-lapack==2025.3.1
473
+onemkl-sycl-lapack==2026.0.0
474
# via torch
475
-onemkl-sycl-rng==2025.3.1
475
+onemkl-sycl-rng==2026.0.0
476
# via torch
477
-onemkl-sycl-sparse==2025.3.1
477
+onemkl-sycl-sparse==2026.0.0
478
# via torch
479
openai==2.44.0
480
# via
@@ -719,6 +719,8 @@ pyyaml==6.0.3
719
# timm
720
# transformers
721
# uvicorn
722
+pyzes==0.1.1
723
+ # via torch
724
pyzmq==27.1.0
725
# via
726
# -c requirements/common.txt
@@ -871,14 +873,14 @@ tabledata==1.3.4
873
# via pytablewriter
874
tabulate==0.10.0
875
# via sacrebleu
874
-tbb==2022.3.1
876
+tbb==2023.0.0
877
# via
878
# intel-opencl-rt
879
# mkl
880
# torch
881
tblib==3.1.0
882
# via -r requirements/test/xpu.in
881
-tcmlib==1.4.1
883
+tcmlib==1.5.0
884
# via
885
# tbb
886
# torch
@@ -910,7 +912,7 @@ tokenizers==0.22.2
912
# -c requirements/common.txt
913
# -r requirements/test/../common.txt
914
# transformers
913
-torch==2.12.0+xpu
915
+torch==2.13.0+xpu
916
# via
917
# -c requirements/xpu.txt
918
# accelerate
@@ -920,7 +922,7 @@ torch==2.12.0+xpu
922
# timm
923
# torchvision
924
# xgrammar
923
-torchvision==0.27.0+xpu
925
+torchvision==0.28.0+xpu
926
# via timm
927
tqdm==4.67.3
928
# via
@@ -946,7 +948,7 @@ transformers==5.14.1
948
# xgrammar
949
triton==3.7.1
950
# via xgrammar
949
-triton-xpu==3.7.1
951
+triton-xpu==3.7.2
952
# via torch
953
typepy==1.3.4
954
# via
@@ -1001,7 +1003,7 @@ typing-inspection==0.4.2
1003
# mcp
1004
# pydantic
1005
# pydantic-settings
1004
-umf==1.0.3
1006
+umf==1.1.0
1007
# via
1008
# intel-cmplr-lib-ur
1009
# torch
requirements/xpu.txt
+3
-3
@@ -12,10 +12,10 @@ jinja2>=3.1.6
12
datasets # for benchmark scripts
13
numba == 0.65.0 # Required for N-gram speculative decoding
14
--extra-index-url=https://download.pytorch.org/whl/xpu
15
-torch==2.12.0
15
+torch==2.13.0
16
torchaudio
17
torchvision
18
torchcodec >= 0.14 # Required for the torchcodec video decoding backend
19
20
-auto_round_lib==0.14.1
21
-vllm_xpu_kernels @ https://github.com/vllm-project/vllm-xpu-kernels/releases/download/v0.1.11.1/vllm_xpu_kernels-0.1.11.1-cp38-abi3-manylinux_2_28_x86_64.whl
20
+auto_round_lib==0.14.2
21
+vllm_xpu_kernels @ https://github.com/vllm-project/vllm-xpu-kernels/releases/download/v0.1.12/vllm_xpu_kernels-0.1.12-cp38-abi3-manylinux_2_28_x86_64.whl
setup.py
+1
-1
@@ -1122,7 +1122,7 @@ if _is_cuda() or _is_hip():
1122
# copying the relevant .py files from the source repository.
1123
ext_modules.append(CMakeExtension(name="vllm.triton_kernels", optional=True))
1124
1125
-if sys.version_info >= (3, 11):
1125
+if not _is_xpu() and sys.version_info >= (3, 11):
1126
ext_modules.append(CMakeExtension(name="vllm.spinloop"))
1127
ext_modules.append(CMakeExtension(name="vllm.fs_io_C"))
1128
vllm/_custom_ops.py
-26
@@ -2391,17 +2391,6 @@ def topk_softmax(
2391
e_score_correction_bias: torch.Tensor | None = None,
2392
is_padding: torch.Tensor | None = None,
2393
) -> None:
2394
- if current_platform.is_xpu():
2395
- # TODO: Remove after vllm-xpu-kernels supports is_padding.
2396
- torch.ops._moe_C.topk_softmax(
2397
- topk_weights,
2398
- topk_ids,
2399
- token_expert_indices,
2400
- gating_output,
2401
- renormalize,
2402
- e_score_correction_bias,
2403
- )
2404
- return
2394
torch.ops._moe_C.topk_softmax(
2395
topk_weights,
2396
topk_ids,
@@ -2447,21 +2436,6 @@ def topk_hash_softplus_sqrt(
2436
hash_indices_table: torch.Tensor | None = None,
2437
is_padding: torch.Tensor | None = None,
2438
) -> None:
2450
- if current_platform.is_xpu():
2451
- # TODO: Remove after vllm-xpu-kernels supports is_padding.
2452
- torch.ops._moe_C.topk_softplus_sqrt(
2453
- topk_weights,
2454
- topk_indices,
2455
- token_expert_indices,
2456
- gating_output,
2457
- renormalize,
2458
- routed_scaling_factor,
2459
- e_score_correction_bias,
2460
- input_tokens,
2461
- hash_indices_table,
2462
- )
2463
- return
2464
-
2439
torch.ops._moe_C.topk_softplus_sqrt(
2440
topk_weights,
2441
topk_indices,