Added DEBUG message to ObjCARC when we optimize objc_retain => objc_retainAutorelasedReturnValue.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171535 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Michael Gottesman 2013-01-04 21:30:38 +00:00
parent 5c0ae4727f
commit 715f6a62a1

View File

@ -2199,7 +2199,17 @@ ObjCARCOpt::OptimizeRetainCall(Function &F, Instruction *Retain) {
// Turn it to an objc_retainAutoreleasedReturnValue..
Changed = true;
++NumPeeps;
DEBUG(dbgs() << "ObjCARCOpt::OptimizeRetainCall: Transforming "
"objc_retainAutoreleasedReturnValue => "
"objc_retain since the operand is not a return value.\n"
" Old: "
<< *Retain << "\n");
cast<CallInst>(Retain)->setCalledFunction(getRetainRVCallee(F.getParent()));
DEBUG(dbgs() << " New: "
<< *Retain << "\n");
}
/// OptimizeRetainRVCall - Turn objc_retainAutoreleasedReturnValue into