未验证 提交 bf606bce 编写于 作者: G gongweibao 提交者: GitHub

Fix grpc log message. (#16735)

上级 7060c8d8
......@@ -16,6 +16,7 @@ limitations under the License. */
#include <nccl.h>
#endif
#include <limits>
#include <memory>
#include <thread> // NOLINT
#include "google/protobuf/io/coded_stream.h"
......@@ -104,8 +105,10 @@ void SerializeToByteBuffer(const std::string& name, framework::Variable* var,
e.WriteVarlengthBeginning(VarMsg::kSerializedFieldNumber,
payload->memory_size());
if (payload->memory_size() >= std::numeric_limits<int>::max()) {
LOG(FATAL) << "AppendZeroCopy varname:" << name
<< ", vlen:" << payload->memory_size();
LOG(FATAL) << "FATAL error: varname:" << name
<< ", vlen:" << payload->memory_size()
<< " >= std::numeric_limits<int>::max():"
<< std::numeric_limits<int>::max() << ", so exit!";
}
// steal reference of tensor data
::grpc::Slice slices[4]; // metadata, tensor, rows meta, rows
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册