mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2025-02-17 02:38:16 +00:00
Fix for testcase Transforms/IndVarsSimplify/2005-02-11-InvokeCrash.ll
and PR504. llvm-svn: 20129
This commit is contained in:
parent
c8d8502a50
commit
8f3f72f2bc
@ -133,6 +133,8 @@ namespace {
|
||||
if ((*UI)->getType() == Ty)
|
||||
if (CastInst *CI = dyn_cast<CastInst>(cast<Instruction>(*UI))) {
|
||||
BasicBlock::iterator It = I; ++It;
|
||||
if (isa<InvokeInst>(I))
|
||||
It = cast<InvokeInst>(I)->getNormalDest()->begin();
|
||||
while (isa<PHINode>(It)) ++It;
|
||||
if (It != BasicBlock::iterator(CI)) {
|
||||
// Splice the cast immediately after the operand in question.
|
||||
|
Loading…
x
Reference in New Issue
Block a user