summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen/SelectionDAG/ScheduleDAGSDNodes.cpp
diff options
context:
space:
mode:
authorEvan Cheng <evan.cheng@apple.com>2009-01-16 20:57:18 +0000
committerEvan Cheng <evan.cheng@apple.com>2009-01-16 20:57:18 +0000
commit968e2e7b3db122ce94cb00857a826edbded2aaed (patch)
treeebba35341c7444747467ad41a1753988f5ff759d /llvm/lib/CodeGen/SelectionDAG/ScheduleDAGSDNodes.cpp
parent10401ce2e0b96a488582b1a584b08e54b9e3d66a (diff)
downloadbcm5719-llvm-968e2e7b3db122ce94cb00857a826edbded2aaed.tar.gz
bcm5719-llvm-968e2e7b3db122ce94cb00857a826edbded2aaed.zip
CreateVirtualRegisters does trivial copy coalescing. If a node def is used by a single CopyToReg, it reuses the virtual register assigned to the CopyToReg. This won't work for SDNode that is a clone or is itself cloned. Disable this optimization for those nodes or it can end up with non-SSA machine instructions.
llvm-svn: 62356
Diffstat (limited to 'llvm/lib/CodeGen/SelectionDAG/ScheduleDAGSDNodes.cpp')
-rw-r--r--llvm/lib/CodeGen/SelectionDAG/ScheduleDAGSDNodes.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/llvm/lib/CodeGen/SelectionDAG/ScheduleDAGSDNodes.cpp b/llvm/lib/CodeGen/SelectionDAG/ScheduleDAGSDNodes.cpp
index 468fd8d4dad..e2c1e285ea4 100644
--- a/llvm/lib/CodeGen/SelectionDAG/ScheduleDAGSDNodes.cpp
+++ b/llvm/lib/CodeGen/SelectionDAG/ScheduleDAGSDNodes.cpp
@@ -33,6 +33,7 @@ SUnit *ScheduleDAGSDNodes::Clone(SUnit *Old) {
SU->isTwoAddress = Old->isTwoAddress;
SU->isCommutable = Old->isCommutable;
SU->hasPhysRegDefs = Old->hasPhysRegDefs;
+ Old->isCloned = true;
return SU;
}
OpenPOWER on IntegriCloud