[llvm] [ConstantRange] Compute exact no-wrap region w/o materializing CR. (PR #223969)

Antonio Frighetto via llvm-commits llvm-commits at lists.llvm.org
Tue Sep 22 02:59:29 PDT 2026


https://github.com/antoniofrighetto commented:

Looks fine in principle, though not very keen on having LLVM_ATTRIBUTE_ALWAYS_INLINE annotations.

I wonder if it could make sense to specialize makeExactNoWrapRegion() for the Add and Sub cases (assuming these are the majority of the cases that would dominate in SCEV hot paths), and continue resorting to makeGuaranteedNoWrapRegion() for Mul and Shl. This would come at cost of slightly duplicating some logic, but would avoid the annotation.

https://github.com/llvm/llvm-project/pull/223969


More information about the llvm-commits mailing list