Browse Source

add ATTR_NAME_ROOT_GRAPH_ID

tags/v1.2.0
wuweikang 3 years ago
parent
commit
ef63b2207a
2 changed files with 5 additions and 2 deletions
  1. +4
    -1
      ge/graph/manager/graph_manager.cc
  2. +1
    -1
      metadef

+ 4
- 1
ge/graph/manager/graph_manager.cc View File

@@ -2466,7 +2466,6 @@ Status GraphManager::ProcessSubGraphWithMultiThreads(GraphManager *graph_manager
GetContext().SetSessionId(session_id);
GetThreadLocalContext() = ge_context;
graph_manager->UpdateLocalOmgContext(root_graph_id);

ComputeGraphPtr compute_graph_tmp = sub_graph_info_ptr->GetSubGraph();
const std::string &engine_name = sub_graph_info_ptr->GetEngineName();
GELOGD("ProcessSubGraphWithMultiThreads start, graph name is %s, engine_name is %s, thread id is %lu",
@@ -2474,6 +2473,10 @@ Status GraphManager::ProcessSubGraphWithMultiThreads(GraphManager *graph_manager
pthread_self());
GE_DUMP(compute_graph_tmp, "OptimizeSubGraphBefore");
GE_CHECK_NOTNULL(compute_graph_tmp);
if (!AttrUtils::SetInt(*compute_graph_tmp, ATTR_NAME_ROOT_GRAPH_ID, root_graph_id)) {
GELOGE(FAILED, "Failed to set attr ATTR_NAME_ROOT_GRAPH_ID for subgraph, graph_id: %u.", root_graph_id);
return FAILED;
}
compute_graph_tmp->SetSessionID(session_id);
Status ret = graph_manager->GetCompilerStages(root_graph_id).optimizer.OptimizeSubGraph(compute_graph_tmp,
compute_graph,


+ 1
- 1
metadef

@@ -1 +1 @@
Subproject commit d19c9c5c92f21a0335c18681dcceed44f3a54ddc
Subproject commit bd2cfdfa85a3d9dcbd7dc825f5759c7f8b3ffa9a

Loading…
Cancel
Save