[llvm] [InstCombine] Handle ceil division idiom (PR #100977)
Antonio Frighetto via llvm-commits
llvm-commits at lists.llvm.org
Mon Jan 6 06:55:51 PST 2025
antoniofrighetto wrote:
> > #84016 has landed.
>
> I think we are still missing to preserve the no overflow guarantee. By the time we visit the last addition, both add nuw i8 %x, %y and the assume(no_overflow) are optimized out (the latter is just constant folded to assume(true)). Shouldn't we emit an assume in the form of x+y < uint_max true instead?
Arguably, this should just happen because the WO has no uses (and provided that I'm not missing anything within the AssumptionCache or other ways to query the no overflow guarantee).
https://github.com/llvm/llvm-project/pull/100977
More information about the llvm-commits
mailing list