[LLVMdev] isSafeToSpeculativelyExecute() for CallInst
nrotem at apple.com
Sun Sep 9 00:37:22 PDT 2012
So we have a bug in canSinkOrHoistInst because it only checks for memory deps.
On Sep 9, 2012, at 8:39 AM, Duncan Sands <baldrick at free.fr> wrote:
> Hi Nadav,
> On 08/09/12 22:51, Nadav Rotem wrote:
>> On Aug 19, 2012, at 2:55 PM, "Kuperstein, Michael M"
>> <michael.m.kuperstein at intel.com <mailto:michael.m.kuperstein at intel.com>> wrote:
>>> Currently, llvm::isSafeToSpeculativelyExecute() always returns false for Call
>>> This has actual performance implications, because loop-invariant code motion
>>> makes this check, and will never hoist instructions that are not safe to
>>> speculatively execute.
>> LICM::canSinkOrHoistInst has special handling for hoisting Call Instructiobns.
>> It looks like readonly functions should be hoisted. Do you have test cases
>> which fail ?
> a readonly/readnone function may contain divide by zero.
> Ciao, Duncan.
> LLVM Developers mailing list
> LLVMdev at cs.uiuc.edu http://llvm.cs.uiuc.edu
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the llvm-dev