commit | 1178fb47018fea531c91ee04e39f30607122e763 | [log] [tgz] |
---|---|---|
author | Bill Wendling <isanbard@gmail.com> | Mon Aug 15 18:21:07 2011 +0000 |
committer | Bill Wendling <isanbard@gmail.com> | Mon Aug 15 18:21:07 2011 +0000 |
tree | 4c322a983098db4344adeefe2f9f6bbf55fd63c2 | |
parent | 6f9d8ffe5e47e3d11176298e849cc8545c2169a2 [diff] [blame] |
Skip the insertion iterator past the landingpad instruction if there. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@137626 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/Transforms/Scalar/CodeGenPrepare.cpp b/lib/Transforms/Scalar/CodeGenPrepare.cpp index 17beeb5..c274b15 100644 --- a/lib/Transforms/Scalar/CodeGenPrepare.cpp +++ b/lib/Transforms/Scalar/CodeGenPrepare.cpp
@@ -411,6 +411,7 @@ if (!InsertedCast) { BasicBlock::iterator InsertPt = UserBB->getFirstNonPHI(); + if (isa<LandingPadInst>(InsertPt)) ++InsertPt; InsertedCast = CastInst::Create(CI->getOpcode(), CI->getOperand(0), CI->getType(), "",