Skip to content

Fix build issue of PR #20 #32

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 9 commits into from
May 28, 2020
6 changes: 3 additions & 3 deletions torch_ipex/csrc/cpu/DevOPs.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -594,9 +594,9 @@ at::Tensor AtenIpexCPUDev::dil_linear_fuse_relu(
output_size.push_back(weight.size(0));

if (self.dim() > 2) {
return dbl::comm::gen_aten_tensor_by(y).reshape(output_size);
return dbl::comm::gen_aten_tensor_by(std::move(y)).reshape(output_size);
}
return dbl::comm::gen_aten_tensor_by(y);
return dbl::comm::gen_aten_tensor_by(std::move(y));
}

at::Tensor dil_linear_backward_input(
Expand Down Expand Up @@ -1036,7 +1036,7 @@ at::Tensor AtenIpexCPUDev::dil_relu_use_dst_for_bwd(const at::Tensor& grad_outpu
dil::tensor gradx;
dil::eltwise_backward::compute(y, grady, gradx,
dil::algorithm::eltwise_relu_use_dst_for_bwd, /*alpha*/ 0.0);
return dbl::comm::gen_aten_tensor_by(gradx);
return dbl::comm::gen_aten_tensor_by(std::move(gradx));
}

at::Tensor AtenIpexCPUDev::dil_threshold_backward(const at::Tensor& grad_output, const at::Tensor& input, at::Scalar threshold) {
Expand Down