[Mlir-commits] [mlir] [mlir][arith] Add ValueBoundsOpInterface external models for the arith integer CeilDiv, RemSI, RemUI, MaxUI, MinUI. (PR #204966)

llvmlistbot at llvm.org llvmlistbot at llvm.org
Sun Jun 21 04:04:46 PDT 2026


================
@@ -17,6 +17,30 @@ namespace mlir {
 namespace arith {
 namespace {
 
+static bool isProvablyNonNegative(Value value, ValueBoundsConstraintSet &cstr) {
+  return cstr.populateAndCompare(
+      /*lhs=*/{value}, ValueBoundsConstraintSet::ComparisonOperator::GE,
+      /*rhs=*/{OpFoldResult(Builder(value.getContext()).getIndexAttr(0))});
----------------
nirhersh wrote:

the clang format doesnt allow this

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


More information about the Mlir-commits mailing list