Reenable a basic SSA DAG builder optimization.
authorAndrew Trick <atrick@apple.com>
Sat, 28 Jul 2012 01:48:15 +0000 (01:48 +0000)
committerAndrew Trick <atrick@apple.com>
Sat, 28 Jul 2012 01:48:15 +0000 (01:48 +0000)
Jakob fixed ProcessImplicifDefs in r159149.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160910 91177308-0d34-0410-b5e6-96231b3b80d8

lib/CodeGen/ScheduleDAGInstrs.cpp

index 110f478f48ea78eb30954e9cda135bec2581916f..5b40cb4a7e264745227b447425c598bb72f5be5a 100644 (file)
@@ -411,12 +411,11 @@ void ScheduleDAGInstrs::addVRegDefDeps(SUnit *SU, unsigned OperIdx) {
   const MachineInstr *MI = SU->getInstr();
   unsigned Reg = MI->getOperand(OperIdx).getReg();
 
-  // SSA defs do not have output/anti dependencies.
+  // Singly defined vregs do not have output/anti dependencies.
   // The current operand is a def, so we have at least one.
-  //
-  // FIXME: This optimization is disabled pending PR13112.
-  //if (llvm::next(MRI.def_begin(Reg)) == MRI.def_end())
-  //  return;
+  // Check here if there are any others...
+  if (llvm::next(MRI.def_begin(Reg)) == MRI.def_end())
+    return;
 
   // Add output dependence to the next nearest def of this vreg.
   //