From 4f73180371f3560acbb4750d9e366c3dc3feea40 Mon Sep 17 00:00:00 2001 From: hanchao Date: Thu, 5 Sep 2024 07:42:13 +0000 Subject: [PATCH] update --- torch/csrc/distributed/c10d/Ops.cpp | 1 + torch/csrc/distributed/c10d/ProcessGroupXCCL.hpp | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/torch/csrc/distributed/c10d/Ops.cpp b/torch/csrc/distributed/c10d/Ops.cpp index 03a5e42874594..4979c57384fcb 100644 --- a/torch/csrc/distributed/c10d/Ops.cpp +++ b/torch/csrc/distributed/c10d/Ops.cpp @@ -516,6 +516,7 @@ REGISTER_C10D_OP(alltoall_) REGISTER_C10D_OP(alltoall_base_) REGISTER_C10D_OP(barrier) +REGISTER_C10D_OP1(allreduce_, XPU) // The following ops are specialized, register them separately TORCH_LIBRARY_IMPL(c10d, CPU, m) { diff --git a/torch/csrc/distributed/c10d/ProcessGroupXCCL.hpp b/torch/csrc/distributed/c10d/ProcessGroupXCCL.hpp index b43403f52f31a..9ad20797afcb6 100644 --- a/torch/csrc/distributed/c10d/ProcessGroupXCCL.hpp +++ b/torch/csrc/distributed/c10d/ProcessGroupXCCL.hpp @@ -38,7 +38,7 @@ using XCCL_KVS = ccl::shared_ptr_class; constexpr const char* XCCL_BACKEND_NAME = "xccl"; // using namespace torch::xpu::xccl; -class TORCH_XPU_API ProcessGroupXCCL : public Backend { +class TORCH_API ProcessGroupXCCL : public Backend { public: class WorkXCCL : public Work { public: