[llvm-commits] [llvm] r50707 - /llvm/branches/non-call-eh/lib/Transforms/Utils/CloneFunction.cpp
Nick Lewycky
nicholas at mxc.ca
Mon May 5 21:04:39 PDT 2008
Author: nicholas
Date: Mon May 5 23:04:39 2008
New Revision: 50707
URL: http://llvm.org/viewvc/llvm-project?rev=50707&view=rev
Log:
Add support for nounwind on BBs to the basic block cloner. This fixes
bugpointing failures with nounwind on BBs.
Modified:
llvm/branches/non-call-eh/lib/Transforms/Utils/CloneFunction.cpp
Modified: llvm/branches/non-call-eh/lib/Transforms/Utils/CloneFunction.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/branches/non-call-eh/lib/Transforms/Utils/CloneFunction.cpp?rev=50707&r1=50706&r2=50707&view=diff
==============================================================================
--- llvm/branches/non-call-eh/lib/Transforms/Utils/CloneFunction.cpp (original)
+++ llvm/branches/non-call-eh/lib/Transforms/Utils/CloneFunction.cpp Mon May 5 23:04:39 2008
@@ -34,7 +34,8 @@
BasicBlock *NewBB = BasicBlock::Create("", F);
if (BB->hasName()) NewBB->setName(BB->getName()+NameSuffix);
NewBB->setUnwindDest(const_cast<BasicBlock*>(BB->getUnwindDest()));
-
+ NewBB->setDoesNotThrow(BB->doesNotThrow());
+
bool hasCalls = false, hasDynamicAllocas = false, hasStaticAllocas = false;
// Loop over all instructions, and copy them over.
More information about the llvm-commits
mailing list