Skip to content

Commit bb7fda6

Browse files
committed
Build XCCL as default and make XCCL the default distributed backend for XPU
1 parent 4a302b5 commit bb7fda6

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -259,7 +259,7 @@ option(USE_NATIVE_ARCH "Use -march=native" OFF)
259259
cmake_dependent_option(USE_MPS "Use MPS for macOS build" ON "MPS_FOUND" OFF)
260260
cmake_dependent_option(USE_NCCL "Use NCCL" ON
261261
"USE_CUDA OR USE_ROCM;UNIX;NOT APPLE" OFF)
262-
cmake_dependent_option(USE_XCCL "Use XCCL" OFF
262+
cmake_dependent_option(USE_XCCL "Use XCCL" ON
263263
"USE_XPU;UNIX;NOT APPLE" OFF)
264264
cmake_dependent_option(USE_RCCL "Use RCCL" ON USE_NCCL OFF)
265265
cmake_dependent_option(USE_STATIC_NCCL "Use static NCCL" OFF "USE_NCCL" OFF)

torch/distributed/distributed_c10d.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -340,7 +340,7 @@ def register_backend(
340340

341341
if devices is not None:
342342
for device in devices:
343-
if device != "cpu" and device != "cuda":
343+
if device != "cpu" and device != "cuda" and device != "xpu":
344344
Backend.default_device_backend_map[device] = name.lower()
345345
Backend.backend_type_map[name.lower()] = ProcessGroup.BackendType.CUSTOM
346346

0 commit comments

Comments
 (0)