[Mlir-commits] [mlir] [mlir][linalg] Add check for 'affine.for' map bound results (PR #127105)

Krzysztof Drewniak llvmlistbot at llvm.org
Thu Feb 13 11:48:43 PST 2025


================
@@ -1902,6 +1902,13 @@ LogicalResult AffineForOp::verifyRegions() {
     if (failed(verifyDimAndSymbolIdentifiers(*this, getUpperBoundOperands(),
                                              getUpperBoundMap().getNumDims())))
       return failure();
+  // Verify that the bound maps produce at least one result.
+  /// Lower bound.
+  if (getLowerBoundMap().getNumResults() < 1)
+    return emitOpError("expected lower bound map to have at least one result");
+  /// Upper bound.
----------------
krzysz00 wrote:

Same

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


More information about the Mlir-commits mailing list