未验证 提交 091ae705 编写于 作者: L Lin Manhui 提交者: GitHub

[Fix] Remove std::trunc() in FloorDivideFunctor and InverseFloorDivideFunctor (#45051)

上级 f05a375c
......@@ -570,7 +570,7 @@ struct FloorDivideFunctor {
#ifndef PADDLE_WITH_XPU_KP
PADDLE_ENFORCE(b != 0, DIV_ERROR_INFO);
#endif
return static_cast<T>(std::trunc(a / b));
return static_cast<T>(a / b);
}
};
......@@ -580,7 +580,7 @@ struct InverseFloorDivideFunctor {
#ifndef PADDLE_WITH_XPU_KP
PADDLE_ENFORCE(a != 0, DIV_ERROR_INFO);
#endif
return static_cast<T>(std::trunc(b / a));
return static_cast<T>(b / a);
}
};
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册