Skip to content

Commit

Permalink
Fix
Browse files Browse the repository at this point in the history
  • Loading branch information
co63oc committed Oct 25, 2024
1 parent 41503fd commit 0c10106
Show file tree
Hide file tree
Showing 6 changed files with 4 additions and 94 deletions.
84 changes: 0 additions & 84 deletions paddle/fluid/operators/collective/mp_allreduce_sum_op.cc

This file was deleted.

2 changes: 0 additions & 2 deletions paddle/phi/kernels/gpu/mp_allreduce_sum_kernel.cu
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,6 @@ namespace phi {
template <typename T, typename Context>
void MpAllReduceSumKernel(const Context& dev_ctx,
const DenseTensor& x,
int ring_id UNUSED,
bool use_calc_stream UNUSED,
DenseTensor* out) {
AllReduceKernel<T, Context>(
dev_ctx, x, static_cast<int>(ReduceType::kRedSum), out);
Expand Down
2 changes: 0 additions & 2 deletions paddle/phi/kernels/kps/mp_allreduce_sum_kernel.kps
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,6 @@ namespace phi {
template <typename T, typename Context>
void MpAllReduceSumKernel(const Context& dev_ctx,
const DenseTensor& x,
int ring_id UNUSED,
bool use_calc_stream UNUSED,
DenseTensor* out) {
AllReduceKernel<T, Context>(
dev_ctx, x, static_cast<int>(ReduceType::kRedSum), out);
Expand Down
2 changes: 0 additions & 2 deletions paddle/phi/kernels/xpu/mp_allreduce_sum_kernel.cc
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,6 @@ namespace phi {
template <typename T, typename Context>
void MpAllReduceSumKernel(const Context& dev_ctx,
const DenseTensor& x,
int ring_id UNUSED,
bool use_calc_stream UNUSED,
DenseTensor* out) {
AllReduceKernel<T, Context>(
dev_ctx, x, static_cast<int>(ReduceType::kRedSum), out);
Expand Down
4 changes: 2 additions & 2 deletions paddle/phi/ops/yaml/inconsistent/static_backward.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -410,8 +410,8 @@
composite : minimum_grad(x, y, out_grad, x_grad, y_grad)

- backward_op : mp_allreduce_sum_grad
forward : mp_allreduce_sum(Tensor x, int ring_id = 0, bool use_calc_stream = false) -> Tensor(out)
args : (Tensor out_grad, int ring_id = 0, bool use_calc_stream = false)
forward : mp_allreduce_sum(Tensor x, int ring_id = 0) -> Tensor(out)
args : (Tensor out_grad, int ring_id = 0)
output : Tensor(x_grad)
invoke : c_identity(out_grad, ring_id, false, false)

Expand Down
4 changes: 2 additions & 2 deletions paddle/phi/ops/yaml/inconsistent/static_ops.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -644,14 +644,14 @@
interfaces : paddle::dialect::InferSymbolicShapeInterface

- op : mp_allreduce_sum
args : (Tensor x, int ring_id = 0, bool use_calc_stream = false)
args : (Tensor x, int ring_id = 0)
output : Tensor(out)
infer_meta :
func : AllReduceInferMeta
param: [x]
kernel :
func : mp_allreduce_sum
param: [x, ring_id, use_calc_stream]
param: [x]
backward: mp_allreduce_sum_grad
inplace: (x -> out)

Expand Down

0 comments on commit 0c10106

Please sign in to comment.