Browse Source

Delete StreamAllocator::ReorderEventNodes

tags/v1.2.0
zhangxiaokun 3 years ago
parent
commit
eaacdb2bc1
3 changed files with 1 additions and 25 deletions
  1. +1
    -17
      ge/graph/build/stream_allocator.cc
  2. +0
    -1
      ge/graph/build/stream_allocator.h
  3. +0
    -7
      ge/graph/build/task_generator.cc

+ 1
- 17
ge/graph/build/stream_allocator.cc View File

@@ -1226,7 +1226,7 @@ Status StreamAllocator::InsertSyncEventNodes() {
}
}

Status status = ReorderEventNodes();
Status status = whole_graph_->InsertGraphEvents();
if (status != SUCCESS) {
GELOGE(status, "Graph ReorderEventNodes failed");
return status;
@@ -1235,22 +1235,6 @@ Status StreamAllocator::InsertSyncEventNodes() {
return SUCCESS;
}

Status StreamAllocator::ReorderEventNodes() const {
Status status = whole_graph_->InsertEventNodes();
if (status != SUCCESS) {
GELOGE(status, "Whole graph InsertEventNodes failed");
return status;
}
for (const auto &subgraph : whole_graph_->GetAllSubgraphs()) {
status = subgraph->InsertEventNodes();
if (status != SUCCESS) {
GELOGE(status, "Subgraph %s InsertEventNodes failed", subgraph->GetName().c_str());
return status;
}
}
return SUCCESS;
}

void StreamAllocator::DumpEvents() {
map<int64_t, vector<NodePtr>> after_refresh_stream_nodes;
for (const auto &node : whole_graph_->GetNodes(whole_graph_->GetGraphUnknownFlag())) {


+ 0
- 1
ge/graph/build/stream_allocator.h View File

@@ -74,7 +74,6 @@ class StreamAllocator {
Status RefreshContinuousEvents();

Status InsertSyncEventNodes();
Status ReorderEventNodes() const;

void DumpEvents();



+ 0
- 7
ge/graph/build/task_generator.cc View File

@@ -533,13 +533,6 @@ Status TaskGenerator::MarkNodeAndSetIndex(ComputeGraphPtr &graph) {
return GE_GRAPH_GRAPH_NODE_NULL;
}

int64_t node_index = 0;
for (auto &node : all_nodes) {
OpDescPtr op_desc = node->GetOpDesc();
GE_CHECK_NOTNULL(op_desc);
op_desc->SetId(node_index++);
}

map<int64_t, vector<OpDescPtr>> all_stream_ops;
for (auto &node : all_nodes) {
OpDescPtr op_desc = node->GetOpDesc();


Loading…
Cancel
Save