Clearing vectors as soon as data is not needed anymore.

This commit is contained in:
DennisOSRM 2012-07-16 13:20:56 +02:00
parent 7467e11147
commit 7261ce3b7f

View File

@ -277,6 +277,9 @@ void EdgeBasedGraphFactory::Run(const char * originalEdgeDataFilename) {
}
}
std::vector<NodeID>().swap(vectorOfComponentSizes);
std::vector<NodeID>().swap(componentsIndex);
//Loop over all turns and generate new set of edges.
//Three nested loop look super-linear, but we are dealing with a linear number of turns only.
for(_NodeBasedDynamicGraph::NodeIterator u = 0; u < _nodeBasedGraph->GetNumberOfNodes(); ++u ) {