[Mlir-commits] [mlir] [mlir][affine] Guard invalid dim attribute in the test-reify-bound pass (PR #129013)

llvmlistbot at llvm.org llvmlistbot at llvm.org
Mon Mar 10 22:28:33 PDT 2025


github-actions[bot] wrote:

<!--LLVM CODE FORMAT COMMENT: {clang-format}-->


:warning: C/C++ code formatter, clang-format found issues in your code. :warning:

<details>
<summary>
You can test this locally with the following command:
</summary>

``````````bash
git-clang-format --diff 72bb0a9a9c6fdde43e1e191f2dc0d5d2d46aff4e ebb7ed397ec59836816f3633bfd909a5403901e2 --extensions cpp -- mlir/test/lib/Dialect/Affine/TestReifyValueBounds.cpp
``````````

</details>

<details>
<summary>
View the diff from clang-format here.
</summary>

``````````diff
diff --git a/mlir/test/lib/Dialect/Affine/TestReifyValueBounds.cpp b/mlir/test/lib/Dialect/Affine/TestReifyValueBounds.cpp
index 975171f405..4231e39179 100644
--- a/mlir/test/lib/Dialect/Affine/TestReifyValueBounds.cpp
+++ b/mlir/test/lib/Dialect/Affine/TestReifyValueBounds.cpp
@@ -95,7 +95,7 @@ static LogicalResult testReifyValueBounds(FunctionOpInterface funcOp,
         return WalkResult::interrupt();
       }
 
-      if(dim.value() >= shapedType.getRank()) {
+      if (dim.value() >= shapedType.getRank()) {
         op->emitOpError("invalid dim for shaped type rank");
         return WalkResult::interrupt();
       }

``````````

</details>


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


More information about the Mlir-commits mailing list