Convert DOUT to DEBUG(errs()...).
[oota-llvm.git] / lib / CodeGen / PrologEpilogInserter.cpp
index 8b05f4c4a3e39d8a71f1424fece1ff955a7380c7..061ac2a2b50f6cf5f93733874538e6d483b29965 100644 (file)
@@ -214,8 +214,6 @@ void PEI::calculateCalleeSavedRegisters(MachineFunction &Fn) {
     }
   }
 
-  FFI->setCalleeSavedInfoValid(true);
-
   if (CSI.empty())
     return;   // Early exit if no callee saved registers are modified!
 
@@ -274,6 +272,8 @@ void PEI::insertCSRSpillsAndRestores(MachineFunction &Fn) {
   MachineFrameInfo *FFI = Fn.getFrameInfo();
   const std::vector<CalleeSavedInfo> &CSI = FFI->getCalleeSavedInfo();
 
+  FFI->setCalleeSavedInfoValid(true);
+
   // Early exit if no callee saved registers are modified!
   if (CSI.empty())
     return;
@@ -637,11 +637,6 @@ void PEI::replaceFrameIndices(MachineFunction &Fn) {
     if (RS) RS->enterBasicBlock(BB);
 
     for (MachineBasicBlock::iterator I = BB->begin(); I != BB->end(); ) {
-      if (I->getOpcode() == TargetInstrInfo::DECLARE) {
-        // Ignore it.
-        ++I;
-        continue;
-      }
 
       if (I->getOpcode() == FrameSetupOpcode ||
           I->getOpcode() == FrameDestroyOpcode) {