Skip to content

Commit

Permalink
update solve_grad_kernel_impl.h for compiling optimization (#57603)
Browse files Browse the repository at this point in the history
  • Loading branch information
yinwei authored Sep 22, 2023
1 parent 87738f1 commit 2552742
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions paddle/phi/kernels/impl/solve_grad_kernel_impl.h
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ limitations under the License. */
#include "paddle/phi/kernels/funcs/reduce_function.h"
#include "paddle/phi/kernels/funcs/reduce_functor.h"
#include "paddle/phi/kernels/impl/solve_kernel_impl.h"
#include "paddle/phi/kernels/reduce_sum_kernel.h"
#include "paddle/phi/kernels/squeeze_kernel.h"
#include "paddle/phi/kernels/unsqueeze_kernel.h"

Expand Down Expand Up @@ -63,8 +64,8 @@ struct ReduceSumForSolvelGrad<GPUContext, T> {
DenseTensor* output,
const std::vector<int>& reduce_dims,
bool keep_dims) {
phi::funcs::ReduceKernel<T, T, kps::AddFunctor, kps::IdentityFunctor<T>>(
dev_ctx, input, output, kps::IdentityFunctor<T>(), reduce_dims);
phi::SumKernel<T, GPUContext>(
dev_ctx, input, reduce_dims, input.dtype(), false, output);
}
};
#endif
Expand Down

0 comments on commit 2552742

Please sign in to comment.