Hongbin Zheng via llvm-dev
2017-Jul-24 21:43 UTC
[llvm-dev] LazyValueInfo vs ScalarEvolution
On Mon, Jul 24, 2017 at 2:29 PM, John Regehr via llvm-dev < llvm-dev at lists.llvm.org> wrote:> On 7/24/17 3:16 PM, Hongbin Zheng via llvm-dev wrote: > >> Thanks, maybe we could use ScalarEvolution in LazyValueInfo if it is >> available? >> > > This should be fairly easy to try, if you want to propose a patch and run > some experiments. The question is whether the benefit in terms of improved > optimization power is worth the compile-time cost.Ok Also, the last time I looked, there seemed to be a fair amount of room for> improvement in LVI and ConstantRange.Could you point some out? Thanks Hongbin> > > John > > > _______________________________________________ > LLVM Developers mailing list > llvm-dev at lists.llvm.org > http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev >-------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20170724/c7446461/attachment.html>
John Regehr via llvm-dev
2017-Jul-24 21:59 UTC
[llvm-dev] LazyValueInfo vs ScalarEvolution
On 07/24/2017 03:43 PM, Hongbin Zheng wrote:> Also, the last time I looked, there seemed to be a fair amount of > room for improvement in LVI and ConstantRange. > > Could you point some out?Check out the TODO items in binaryAnd and BinaryOr in ConstantRange.cpp. There are some missing cases in the switch in ConstantRange::binaryOp, such as xor and ashr. Argh this is embarrassing, I have some unfinished work sitting in Phabricator that could use a helper if you have time to take a look: https://reviews.llvm.org/D19859 https://reviews.llvm.org/D20669 https://reviews.llvm.org/D19867 https://reviews.llvm.org/D19559 John
John Regehr via llvm-dev
2017-Jul-24 22:08 UTC
[llvm-dev] LazyValueInfo vs ScalarEvolution
Also I should add that I strongly doubt that it will be acceptable to simply call ScalarEvolution's integer range analysis from LVI. The right answer is no doubt more nuanced and the actual experts in this stuff are here and hopefully they can chime in with opinions. Also, I am hoping to get together with a few people who care about LVI at the October dev meeting, you should join if you are going to attend. John On 07/24/2017 03:59 PM, John Regehr wrote:> On 07/24/2017 03:43 PM, Hongbin Zheng wrote: >> Also, the last time I looked, there seemed to be a fair amount of >> room for improvement in LVI and ConstantRange. >> >> Could you point some out? > > Check out the TODO items in binaryAnd and BinaryOr in ConstantRange.cpp. > > There are some missing cases in the switch in ConstantRange::binaryOp, > such as xor and ashr. > > Argh this is embarrassing, I have some unfinished work sitting in > Phabricator that could use a helper if you have time to take a look: > > https://reviews.llvm.org/D19859 > https://reviews.llvm.org/D20669 > https://reviews.llvm.org/D19867 > https://reviews.llvm.org/D19559 > > John >