[Mlir-commits] [mlir] [mlir][linalg] fix linalg.batch_reduce_matmul auto cast (PR #102585)

llvmlistbot at llvm.org llvmlistbot at llvm.org
Fri Aug 9 01:48:32 PDT 2024


github-actions[bot] wrote:

<!--LLVM CODE FORMAT COMMENT: {darker}-->


:warning: Python code formatter, darker found issues in your code. :warning:

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

``````````bash
darker --check --diff -r d38bae3c773f0fda578097dc5a35114a83cfc2af...e95fedef54aa3a101cf2a7752b7e8b97181e3037 mlir/python/mlir/dialects/linalg/opdsl/ops/core_named_ops.py
``````````

</details>

<details>
<summary>
View the diff from darker here.
</summary>

``````````diff
--- core_named_ops.py	2024-08-09 08:41:11.000000 +0000
+++ core_named_ops.py	2024-08-09 08:47:59.687222 +0000
@@ -590,12 +590,13 @@
     Numeric casting is performed on the operands to the inner multiply, promoting
     them to the same data type as the accumulator/output.
     """
     domain(D.b, D.m, D.n, D.k)
     implements(ContractionOpInterface)
-    C[D.m, D.n] += TypeFn.cast_signed(
-        U, A[D.b, D.m, D.k]) * TypeFn.cast_signed(U, B[D.b, D.k, D.n]) 
+    C[D.m, D.n] += TypeFn.cast_signed(U, A[D.b, D.m, D.k]) * TypeFn.cast_signed(
+        U, B[D.b, D.k, D.n]
+    )
 
 
 @linalg_structured_op
 def matvec(
     A=TensorDef(T1, S.M, S.N), y=TensorDef(T2, S.N), x=TensorDef(U, S.M, output=True)

``````````

</details>


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


More information about the Mlir-commits mailing list