Back to PBT run

input.generic.mlir

"builtin.module"() ({
  "func.func"() <{function_type = (index) -> index, sym_name = "native_helper"}> ({
  ^bb0(%arg22: index):
    "func.return"(%arg22) : (index) -> ()
  }) : () -> ()
  "dataflow.thread"() <{domain = #dataflow.thread_domain<dense>, function_type = (memref<8xindex>, memref<8xindex>, memref<4x4xindex>, index) -> (), sym_name = "t0", sym_visibility = "private"}> ({
  ^bb0(%arg10: memref<8xindex>, %arg11: memref<8xindex>, %arg12: memref<4x4xindex>, %arg13: index, %arg14: none):
    %4 = "arith.constant"() <{value = 0 : index}> : () -> index
    %5 = "arith.constant"() <{value = 3 : index}> : () -> index
    "memref.store"(%5, %arg10, %4) : (index, memref<8xindex>, index) -> ()
    "loom.spatial_region"(%arg13, %arg11, %arg12) <{graph_name = "g_t0_0", operandSegmentSizes = array<i32: 1, 0, 2, 0>, resultSegmentSizes = array<i32: 0, 0>, source_maps = []}> ({
    ^bb0(%arg15: index, %arg16: memref<8xindex>, %arg17: memref<4x4xindex>):
      %6 = "arith.constant"() <{value = 0 : index}> : () -> index
      %7 = "arith.constant"() <{value = 1 : index}> : () -> index
      %8 = "arith.constant"() <{value = 1 : index}> : () -> index
      %9 = "arith.constant"() <{value = 7 : index}> : () -> index
      "scf.for"(%6, %arg15, %7) ({
      ^bb0(%arg18: index):
        "scf.parallel"(%6, %8, %7) <{operandSegmentSizes = array<i32: 1, 1, 1, 0>}> ({
        ^bb0(%arg19: index):
          %10 = "scf.for"(%6, %arg15, %7, %arg19) ({
          ^bb0(%arg20: index, %arg21: index):
            %11 = "arith.addi"(%arg21, %7) <{overflowFlags = #arith.overflow<none>}> : (index, index) -> index
            "scf.yield"(%11) : (index) -> ()
          }) : (index, index, index, index) -> index
          "memref.store"(%10, %arg16, %arg19) : (index, memref<8xindex>, index) -> ()
          "scf.reduce"() : () -> ()
        }) : (index, index, index) -> ()
        "scf.yield"() : () -> ()
      }) : (index, index, index) -> ()
      "loom.spatial_yield"() <{operandSegmentSizes = array<i32: 0, 0>}> : () -> ()
    }) : (index, memref<8xindex>, memref<4x4xindex>) -> ()
    "dataflow.thread.yield"() : () -> ()
  }) : () -> ()
  "dataflow.thread"() <{domain = #dataflow.thread_domain<dense>, function_type = (memref<8xindex>, memref<8xindex>, memref<4x4xindex>, index) -> (), sym_name = "t1", sym_visibility = "private"}> ({
  ^bb0(%arg0: memref<8xindex>, %arg1: memref<8xindex>, %arg2: memref<4x4xindex>, %arg3: index, %arg4: none):
    "loom.spatial_region"(%arg3, %arg1, %arg2) <{graph_name = "g_t1_0", operandSegmentSizes = array<i32: 1, 0, 2, 0>, resultSegmentSizes = array<i32: 0, 0>, source_maps = []}> ({
    ^bb0(%arg5: index, %arg6: memref<8xindex>, %arg7: memref<4x4xindex>):
      %0 = "arith.constant"() <{value = 0 : index}> : () -> index
      %1 = "arith.constant"() <{value = 1 : index}> : () -> index
      %2 = "arith.constant"() <{value = 1 : index}> : () -> index
      %3 = "arith.constant"() <{value = 7 : index}> : () -> index
      "scf.parallel"(%0, %2, %1) <{operandSegmentSizes = array<i32: 1, 1, 1, 0>}> ({
      ^bb0(%arg8: index):
        "scf.parallel"(%0, %2, %1) <{operandSegmentSizes = array<i32: 1, 1, 1, 0>}> ({
        ^bb0(%arg9: index):
          "memref.store"(%3, %arg7, %arg8, %arg9) : (index, memref<4x4xindex>, index, index) -> ()
          "scf.reduce"() : () -> ()
        }) : (index, index, index) -> ()
        "scf.reduce"() : () -> ()
      }) : (index, index, index) -> ()
      "loom.spatial_yield"() <{operandSegmentSizes = array<i32: 0, 0>}> : () -> ()
    }) : (index, memref<8xindex>, memref<4x4xindex>) -> ()
    "dataflow.thread.yield"() : () -> ()
  }) : () -> ()
}) : () -> ()