There is no need to clone over nodes that are going to be dead anyway
llvm-svn: 11157
This commit is contained in:
parent
92affee3e7
commit
40862c7578
|
@ -1112,9 +1112,11 @@ void DSGraph::cloneInto(const DSGraph &G, DSScalarMap &OldValMap,
|
|||
BitsToClear |= DSNode::DEAD; // Clear dead flag...
|
||||
for (unsigned i = 0, e = G.Nodes.size(); i != e; ++i) {
|
||||
DSNode *Old = G.Nodes[i];
|
||||
DSNode *New = new DSNode(*Old, this);
|
||||
New->maskNodeTypes(~BitsToClear);
|
||||
OldNodeMap[Old] = New;
|
||||
if (!Old->isForwarding()) {
|
||||
DSNode *New = new DSNode(*Old, this);
|
||||
New->maskNodeTypes(~BitsToClear);
|
||||
OldNodeMap[Old] = New;
|
||||
}
|
||||
}
|
||||
#ifndef NDEBUG
|
||||
Timer::addPeakMemoryMeasurement();
|
||||
|
|
Loading…
Reference in New Issue