Browse Source

!1601 Variable memory reuse

From: @tangqunzhang
Reviewed-by: @wqtshg,@ji_chen
Signed-off-by: @ji_chen
tags/v1.3.0
mindspore-ci-bot Gitee 4 years ago
parent
commit
3a3eecd806
1 changed files with 1 additions and 1 deletions
  1. +1
    -1
      ge/graph/manager/graph_var_manager.cc

+ 1
- 1
ge/graph/manager/graph_var_manager.cc View File

@@ -556,7 +556,7 @@ ge::Status VarManager::AssignVarMem(const std::string &var_name, const ge::GeTen
// reuse old format variable memory
if (result == SUCCESS) {
result = var_resource_->GetVarAddr(
var_name, tensor_desc, reinterpret_cast<uint8_t **>(reinterpret_cast<uintptr_t>(&mem_offset)), memory_type);
var_name, cur_tensor_desc, reinterpret_cast<uint8_t **>(reinterpret_cast<uintptr_t>(&mem_offset)), memory_type);
if (result == SUCCESS) {
result = TensorUtils::GetSize(cur_tensor_desc, cur_tensor_desc_size);
GELOGD("tensor_desc_size is %ld, cur_tensor_desc_size is %ld, memoffset is %zu", tensor_desc_size,


Loading…
Cancel
Save