From 3fba7d16b41dfbefe3b1be6bc0ab94c017728f79 Mon Sep 17 00:00:00 2001 From: rdivacky Date: Fri, 15 Jan 2010 15:37:28 +0000 Subject: Update LLVM to 93512. --- lib/Transforms/IPO/MergeFunctions.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'lib/Transforms/IPO/MergeFunctions.cpp') diff --git a/lib/Transforms/IPO/MergeFunctions.cpp b/lib/Transforms/IPO/MergeFunctions.cpp index b2bdabc..fa8845b 100644 --- a/lib/Transforms/IPO/MergeFunctions.cpp +++ b/lib/Transforms/IPO/MergeFunctions.cpp @@ -498,7 +498,7 @@ static void ThunkGToF(Function *F, Function *G) { CallInst *CI = CallInst::Create(F, Args.begin(), Args.end(), "", BB); CI->setTailCall(); CI->setCallingConv(F->getCallingConv()); - if (NewG->getReturnType() == Type::getVoidTy(F->getContext())) { + if (NewG->getReturnType()->isVoidTy()) { ReturnInst::Create(F->getContext(), BB); } else if (CI->getType() != NewG->getReturnType()) { Value *BCI = new BitCastInst(CI, NewG->getReturnType(), "", BB); @@ -633,17 +633,17 @@ bool MergeFunctions::runOnModule(Module &M) { bool LocalChanged; do { LocalChanged = false; - DEBUG(errs() << "size: " << FnMap.size() << "\n"); + DEBUG(dbgs() << "size: " << FnMap.size() << "\n"); for (std::map >::iterator I = FnMap.begin(), E = FnMap.end(); I != E; ++I) { std::vector &FnVec = I->second; - DEBUG(errs() << "hash (" << I->first << "): " << FnVec.size() << "\n"); + DEBUG(dbgs() << "hash (" << I->first << "): " << FnVec.size() << "\n"); for (int i = 0, e = FnVec.size(); i != e; ++i) { for (int j = i + 1; j != e; ++j) { bool isEqual = equals(FnVec[i], FnVec[j]); - DEBUG(errs() << " " << FnVec[i]->getName() + DEBUG(dbgs() << " " << FnVec[i]->getName() << (isEqual ? " == " : " != ") << FnVec[j]->getName() << "\n"); -- cgit v1.1