[PATCH] D22413: [ValueTracking] Teach isSafeToSpeculativelyExecute() about the speculatable attribute
Tom Stellard via llvm-commits
llvm-commits at lists.llvm.org
Fri Jul 15 11:04:52 PDT 2016
tstellarAMD added inline comments.
================
Comment at: lib/Analysis/ValueTracking.cpp:3120-3121
@@ -3119,2 +3119,4 @@
}
case Instruction::Call: {
+ const CallInst *CI = cast<CallInst>(Inst);
+ const Function *Callee = CI->getCalledFunction();
----------------
hfinkel wrote:
> arsenm wrote:
> > Is invoke allowed to be speculatable?
> No. The invoked function might throw. If it can't throw, then we'll convert it into a regular call during simplification.
So do I need to check for invoke here, or is it safe to assume that functions referenced by invoke will never have the speculatable attribute.?
https://reviews.llvm.org/D22413
More information about the llvm-commits
mailing list