OSDN Git Service

Added DEBUG message for ObjCARC when we zap a push/pop pair in ObjCARCAPElim::OptimizeBB.
authorMichael Gottesman <mgottesman@apple.com>
Thu, 3 Jan 2013 08:09:17 +0000 (08:09 +0000)
committerMichael Gottesman <mgottesman@apple.com>
Thu, 3 Jan 2013 08:09:17 +0000 (08:09 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171464 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Transforms/Scalar/ObjCARC.cpp

index 3201933..403e064 100644 (file)
@@ -995,6 +995,9 @@ bool ObjCARCAPElim::OptimizeBB(BasicBlock *BB) {
       // zap the pair.
       if (Push && cast<CallInst>(Inst)->getArgOperand(0) == Push) {
         Changed = true;
+        DEBUG(dbgs() << "ObjCARCAPElim: OptimizeBB: Zapping push pop autorelease pair:\n"
+                     << "                           Pop: " << *Inst << "\n"
+                     << "                           Push: " << *Push << "\n");
         Inst->eraseFromParent();
         Push->eraseFromParent();
       }