[Mlir-commits] [mlir] [mlir][linalg] Emit a warning when tile_using_forall generates non thread-safe code (PR #80813)

Oleksandr Alex Zinenko llvmlistbot at llvm.org
Thu Mar 14 07:12:59 PDT 2024


================
@@ -586,3 +586,103 @@ module attributes {transform.with_named_sequence} {
     transform.yield
   }
 }
+
+// -----
+
+#map = affine_map<(d0, d1) -> (d0, d1)>
+#map1 = affine_map<(d0, d1) -> (d0)>
+
+func.func @tile_thread_safety1(%arg0: tensor<100x300xf32>, %arg1: tensor<100xf32>) -> tensor<100xf32> {
+  // expected-warning at +1 {{tiling is not thread safe at axis #1}}
----------------
ftynse wrote:

Nit: using `@below` saves you from brittle line computations.

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


More information about the Mlir-commits mailing list