forked from OSchip/llvm-project
ignore 'invoke new' in isInstructionTriviallyDead, since most callers are not ready to handle invokes. instcombine will take care of this.
llvm-svn: 159440
This commit is contained in:
parent
513f0238d8
commit
b37ef71ce1
|
@ -265,7 +265,8 @@ bool llvm::isInstructionTriviallyDead(Instruction *I) {
|
|||
return isa<UndefValue>(II->getArgOperand(1));
|
||||
}
|
||||
|
||||
if (isAllocLikeFn(I)) return true;
|
||||
if (isAllocLikeFn(I))
|
||||
return isa<CallInst>(I); // do not mess around with invoke here
|
||||
|
||||
if (CallInst *CI = isFreeCall(I))
|
||||
if (Constant *C = dyn_cast<Constant>(CI->getArgOperand(0)))
|
||||
|
|
Loading…
Reference in New Issue