[llvm-branch-commits] [llvm-branch] r91637 - /llvm/branches/Apple/Zoidberg/lib/CodeGen/PHIElimination.cpp

Bill Wendling isanbard at gmail.com
Thu Dec 17 15:49:23 PST 2009


Author: void
Date: Thu Dec 17 17:49:23 2009
New Revision: 91637

URL: http://llvm.org/viewvc/llvm-project?rev=91637&view=rev
Log:
$ svn merge -c 91634 https://llvm.org/svn/llvm-project/llvm/trunk
--- Merging r91634 into '.':
U    lib/CodeGen/StrongPHIElimination.cpp
U    lib/CodeGen/PHIElimination.cpp
$ svn merge -c 91635 https://llvm.org/svn/llvm-project/llvm/trunk
--- Merging r91635 into '.':
G    lib/CodeGen/StrongPHIElimination.cpp


Modified:
    llvm/branches/Apple/Zoidberg/lib/CodeGen/PHIElimination.cpp

Modified: llvm/branches/Apple/Zoidberg/lib/CodeGen/PHIElimination.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/branches/Apple/Zoidberg/lib/CodeGen/PHIElimination.cpp?rev=91637&r1=91636&r2=91637&view=diff

==============================================================================
--- llvm/branches/Apple/Zoidberg/lib/CodeGen/PHIElimination.cpp (original)
+++ llvm/branches/Apple/Zoidberg/lib/CodeGen/PHIElimination.cpp Thu Dec 17 17:49:23 2009
@@ -70,7 +70,7 @@
     Changed |= EliminatePHINodes(Fn, *I);
 
   // Remove dead IMPLICIT_DEF instructions.
-  for (SmallPtrSet<MachineInstr*,4>::iterator I = ImpDefs.begin(),
+  for (SmallPtrSet<MachineInstr*, 4>::iterator I = ImpDefs.begin(),
          E = ImpDefs.end(); I != E; ++I) {
     MachineInstr *DefMI = *I;
     unsigned DefReg = DefMI->getOperand(0).getReg();
@@ -342,7 +342,8 @@
 bool llvm::PHIElimination::SplitPHIEdges(MachineFunction &MF,
                                          MachineBasicBlock &MBB,
                                          LiveVariables &LV) {
-  if (MBB.empty() || MBB.front().getOpcode() != TargetInstrInfo::PHI)
+  if (MBB.empty() || MBB.front().getOpcode() != TargetInstrInfo::PHI ||
+      MBB.isLandingPad())
     return false;   // Quick exit for basic blocks without PHIs.
 
   for (MachineBasicBlock::const_iterator BBI = MBB.begin(), BBE = MBB.end();





More information about the llvm-branch-commits mailing list