[Mlir-commits] [mlir] [mlir][Tosa]: Add folder to ReciprocalOp of splat constant inputs (PR #78137)

Kai Sasaki llvmlistbot at llvm.org
Mon Jan 15 20:35:45 PST 2024


================
@@ -613,3 +613,16 @@ func.func nested @fold_tile_rank_zero() -> tensor<i32> {
   %1 = tosa.tile %0 {multiples = array<i64>} : (tensor<i32>) -> tensor<i32>
   return %1 : tensor<i32>
 }
+
+// -----
+
+// CHECK-LABEL: @fold_reciprocal
+func.func nested @fold_reciprocal() -> tensor<3x600x1200xf32> {
----------------
Lewuathe wrote:

We may want to add the test case to check the int-type operation is not folded? 

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


More information about the Mlir-commits mailing list