mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-08-15 06:29:05 +00:00
There is no need to clone over nodes that are going to be dead anyway
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@11157 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -1112,10 +1112,12 @@ void DSGraph::cloneInto(const DSGraph &G, DSScalarMap &OldValMap,
|
|||||||
BitsToClear |= DSNode::DEAD; // Clear dead flag...
|
BitsToClear |= DSNode::DEAD; // Clear dead flag...
|
||||||
for (unsigned i = 0, e = G.Nodes.size(); i != e; ++i) {
|
for (unsigned i = 0, e = G.Nodes.size(); i != e; ++i) {
|
||||||
DSNode *Old = G.Nodes[i];
|
DSNode *Old = G.Nodes[i];
|
||||||
|
if (!Old->isForwarding()) {
|
||||||
DSNode *New = new DSNode(*Old, this);
|
DSNode *New = new DSNode(*Old, this);
|
||||||
New->maskNodeTypes(~BitsToClear);
|
New->maskNodeTypes(~BitsToClear);
|
||||||
OldNodeMap[Old] = New;
|
OldNodeMap[Old] = New;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
#ifndef NDEBUG
|
#ifndef NDEBUG
|
||||||
Timer::addPeakMemoryMeasurement();
|
Timer::addPeakMemoryMeasurement();
|
||||||
#endif
|
#endif
|
||||||
|
Reference in New Issue
Block a user