From b2c9de02f90db86bda9cc1909d6838111331c8f8 Mon Sep 17 00:00:00 2001 From: "gengchao4@huawei.com" Date: Wed, 14 Apr 2021 11:31:28 +0800 Subject: [PATCH] bugfix for check offset --- ge/graph/build/memory/graph_mem_assigner.cc | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/ge/graph/build/memory/graph_mem_assigner.cc b/ge/graph/build/memory/graph_mem_assigner.cc index 540626bb..c3721554 100755 --- a/ge/graph/build/memory/graph_mem_assigner.cc +++ b/ge/graph/build/memory/graph_mem_assigner.cc @@ -1258,6 +1258,11 @@ Status GraphMemoryAssigner::CheckOffset() { } ge::Status GraphMemoryAssigner::CheckRefNodeOffset(const NodePtr &node) { + GE_CHECK_NOTNULL(node); + // data and netoutput no need check because only data's output or netoutput's input is used + if (node->GetType() == DATA || node->GetType() == NETOUTPUT) { + return ge::SUCCESS; + } std::map out2ins; GE_CHK_STATUS_RET(TryGetNodeRefIndexes(node, out2ins), "[Get][RefIndexes]fail for node: %s", node->GetName().c_str()); auto opdesc = node->GetOpDesc();