未验证 提交 95a2b5f5 编写于 作者: Q Qiao Longfei 提交者: GitHub

fix mac build of sendrecvop_utils (#12272)

上级 2b2406e5
...@@ -28,10 +28,12 @@ namespace distributed { ...@@ -28,10 +28,12 @@ namespace distributed {
using VarMsg = sendrecv::VariableMessage; using VarMsg = sendrecv::VariableMessage;
#ifdef PADDLE_WITH_CUDA
void* GetVarPayLoad(const std::string varname, int64_t size) { void* GetVarPayLoad(const std::string varname, int64_t size) {
platform::CUDAPinnedPlace cuda_pinned; platform::CUDAPinnedPlace cuda_pinned;
return memory::Alloc(cuda_pinned, size); return memory::Alloc(cuda_pinned, size);
} }
#endif
void GetTensorPayload(framework::Variable* var, void GetTensorPayload(framework::Variable* var,
const platform::DeviceContext& ctx, VarMsg* request, const platform::DeviceContext& ctx, VarMsg* request,
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册