[PATCH] D45150: Less conservative LoopSafetyInfo for headers

Piotr Padlewski via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu May 10 07:33:22 PDT 2018


Prazek added a comment.

In https://reviews.llvm.org/D45150#1093811, @reames wrote:

> Specifically NOT okay to land as is.  The quadratic complexity concern is a real one and the window chosen here is very likely too large.
>
> And if you're concern is purely LICM, this patch is no longer needed at all.  I introduced a surgical fix for LICM which solves this without the need for O(n^2) work.  Unfortunately, that approach only works for LICM (not, store promotion or other users of MustExecute).  Unfortunately, as you've found there don't appear to be any good cheap ways to ask ordering questions around instructions within a basic block.  If there were, we could just keep track of the first throwing instruction.
>
> You could consider trying to wire in the caching needed for OrderedBasicBlock, but again, that's only needed if you're concern is different consumer than LICM


This approach was to satisfy this patch:
https://reviews.llvm.org/D45151

I will check in the meantime if your fix is enough to fix it, but I am concerned that it might be not enough.


Repository:
  rL LLVM

https://reviews.llvm.org/D45150





More information about the llvm-commits mailing list