diff --git a/mlir/include/mlir/Dialect/Linalg/TransformOps/LinalgTransformOps.td b/mlir/include/mlir/Dialect/Linalg/TransformOps/LinalgTransformOps.td --- a/mlir/include/mlir/Dialect/Linalg/TransformOps/LinalgTransformOps.td +++ b/mlir/include/mlir/Dialect/Linalg/TransformOps/LinalgTransformOps.td @@ -819,7 +819,7 @@ loop nests, which can be empty. }]; - // Also allow any !pdl.operation for simpler composition. Non-tensor.pad ops + // Also allow any payload operation for simpler composition. Non-tensor.pad ops // will be dropped from the results. let arguments = (ins TransformHandleTypeInterface:$target, @@ -862,7 +862,7 @@ tensor.pad operations, which can be empty. }]; - // Also allow any !pdl.operation for simpler composition. Non-tensor.pad ops + // Also allow any operation for simpler composition. Non-tensor.pad ops // will be dropped from the results. let arguments = (ins TransformHandleTypeInterface:$target, diff --git a/mlir/include/mlir/Dialect/Transform/IR/TransformOps.td b/mlir/include/mlir/Dialect/Transform/IR/TransformOps.td --- a/mlir/include/mlir/Dialect/Transform/IR/TransformOps.td +++ b/mlir/include/mlir/Dialect/Transform/IR/TransformOps.td @@ -77,16 +77,16 @@ ```mlir %result = transform.alternatives %scope { - ^bb0(%arg0: !pdl.operation): + ^bb0(%arg0: !transform.any_op): // Try a fallible transformation. %0 = transform.fallible %arg0 // ... // If succeeded, yield the the result of the transformation. - transform.yield %0 : !pdl.operation + transform.yield %0 : !transform.any_op }, { - ^bb0(%arg0: !pdl.operation): + ^bb0(%arg0: !transform.any_op): // Otherwise, the second alternative is tried and it always succeeds by // returning the original handle. - transform.yield %arg0 : !pdl.operation + transform.yield %arg0 : !transform.any_op } ``` }]; @@ -767,7 +767,7 @@ ```mlir transform.with_pdl_patterns { - ^bb0(%arg0: !pdl.operation): + ^bb0(%arg0: !transform.any_op): pdl.pattern @my_pattern : benefit(1) { %0 = pdl.operation //... // Regular PDL goes here. @@ -775,7 +775,7 @@ } sequence %arg0 failures(propagate) { - ^bb0(%arg1: !pdl.operation): + ^bb0(%arg1: !transform.any_op): %1 = pdl_match @my_pattern in %arg1 // Use %1 as handle } diff --git a/mlir/test/Dialect/SCF/transform-op-coalesce.mlir b/mlir/test/Dialect/SCF/transform-op-coalesce.mlir --- a/mlir/test/Dialect/SCF/transform-op-coalesce.mlir +++ b/mlir/test/Dialect/SCF/transform-op-coalesce.mlir @@ -23,9 +23,9 @@ } transform.sequence failures(propagate) { -^bb1(%arg1: !pdl.operation): - %0 = transform.structured.match ops{["scf.for"]} attributes {coalesce} in %arg1 : (!pdl.operation) -> !pdl.operation - %1 = transform.cast %0 : !pdl.operation to !transform.op<"scf.for"> +^bb1(%arg1: !transform.any_op): + %0 = transform.structured.match ops{["scf.for"]} attributes {coalesce} in %arg1 : (!transform.any_op) -> !transform.any_op + %1 = transform.cast %0 : !transform.any_op to !transform.op<"scf.for"> %2 = transform.loop.coalesce %1: (!transform.op<"scf.for">) -> (!transform.op<"scf.for">) } @@ -49,9 +49,9 @@ } transform.sequence failures(propagate) { -^bb1(%arg1: !pdl.operation): - %0 = transform.structured.match ops{["affine.for"]} attributes {coalesce} in %arg1 : (!pdl.operation) -> !pdl.operation - %1 = transform.cast %0 : !pdl.operation to !transform.op<"affine.for"> +^bb1(%arg1: !transform.any_op): + %0 = transform.structured.match ops{["affine.for"]} attributes {coalesce} in %arg1 : (!transform.any_op) -> !transform.any_op + %1 = transform.cast %0 : !transform.any_op to !transform.op<"affine.for"> %2 = transform.loop.coalesce %1 : (!transform.op<"affine.for">) -> (!transform.op<"affine.for">) } @@ -84,9 +84,9 @@ } transform.sequence failures(propagate) { -^bb1(%arg1: !pdl.operation): - %0 = transform.structured.match ops{["scf.for"]} attributes {coalesce} in %arg1 : (!pdl.operation) -> !pdl.operation - %1 = transform.cast %0 : !pdl.operation to !transform.op<"scf.for"> +^bb1(%arg1: !transform.any_op): + %0 = transform.structured.match ops{["scf.for"]} attributes {coalesce} in %arg1 : (!transform.any_op) -> !transform.any_op + %1 = transform.cast %0 : !transform.any_op to !transform.op<"scf.for"> %2 = transform.loop.coalesce %1 : (!transform.op<"scf.for">) -> (!transform.op<"scf.for">) transform.loop.unroll %2 {factor = 3} : !transform.op<"scf.for"> } diff --git a/mlir/test/Dialect/SCF/transform-ops-invalid.mlir b/mlir/test/Dialect/SCF/transform-ops-invalid.mlir --- a/mlir/test/Dialect/SCF/transform-ops-invalid.mlir +++ b/mlir/test/Dialect/SCF/transform-ops-invalid.mlir @@ -11,9 +11,9 @@ } transform.sequence failures(propagate) { -^bb1(%arg1: !pdl.operation): - %0 = transform.structured.match ops{["affine.for"]} attributes {coalesce} in %arg1 : (!pdl.operation) -> !pdl.operation - %1 = transform.cast %0 : !pdl.operation to !transform.op<"affine.for"> +^bb1(%arg1: !transform.any_op): + %0 = transform.structured.match ops{["affine.for"]} attributes {coalesce} in %arg1 : (!transform.any_op) -> !transform.any_op + %1 = transform.cast %0 : !transform.any_op to !transform.op<"affine.for"> // expected-error @below {{failed to coalesce}} %2 = transform.loop.coalesce %1: (!transform.op<"affine.for">) -> (!transform.op<"affine.for">) } @@ -28,9 +28,9 @@ } transform.sequence failures(propagate) { -^bb1(%arg1: !pdl.operation): - %0 = transform.structured.match ops{["arith.addi"]} in %arg1 : (!pdl.operation) -> !pdl.operation - %1 = transform.loop.get_parent_for %0 { affine = true } : (!pdl.operation) -> !transform.op<"affine.for"> +^bb1(%arg1: !transform.any_op): + %0 = transform.structured.match ops{["arith.addi"]} in %arg1 : (!transform.any_op) -> !transform.any_op + %1 = transform.loop.get_parent_for %0 { affine = true } : (!transform.any_op) -> !transform.op<"affine.for"> // expected-error @below {{failed to unroll}} transform.loop.unroll %1 { factor = 8 } : !transform.op<"affine.for"> } diff --git a/mlir/test/Dialect/SCF/transform-ops.mlir b/mlir/test/Dialect/SCF/transform-ops.mlir --- a/mlir/test/Dialect/SCF/transform-ops.mlir +++ b/mlir/test/Dialect/SCF/transform-ops.mlir @@ -16,12 +16,12 @@ } transform.sequence failures(propagate) { -^bb1(%arg1: !pdl.operation): - %0 = transform.structured.match ops{["arith.addi"]} in %arg1 : (!pdl.operation) -> !pdl.operation +^bb1(%arg1: !transform.any_op): + %0 = transform.structured.match ops{["arith.addi"]} in %arg1 : (!transform.any_op) -> !transform.any_op // CHECK: = transform.loop.get_parent_for - %1 = transform.loop.get_parent_for %0 : (!pdl.operation) -> !transform.op<"scf.for"> - %2 = transform.loop.get_parent_for %0 { num_loops = 2 } : (!pdl.operation) -> !transform.op<"scf.for"> - %3 = transform.loop.get_parent_for %0 { num_loops = 3 } : (!pdl.operation) -> !transform.op<"scf.for"> + %1 = transform.loop.get_parent_for %0 : (!transform.any_op) -> !transform.op<"scf.for"> + %2 = transform.loop.get_parent_for %0 { num_loops = 2 } : (!transform.any_op) -> !transform.op<"scf.for"> + %3 = transform.loop.get_parent_for %0 { num_loops = 3 } : (!transform.any_op) -> !transform.op<"scf.for"> transform.test_print_remark_at_operand %1, "third loop" : !transform.op<"scf.for"> transform.test_print_remark_at_operand %2, "second loop" : !transform.op<"scf.for"> transform.test_print_remark_at_operand %3, "first loop" : !transform.op<"scf.for"> @@ -36,10 +36,10 @@ } transform.sequence failures(propagate) { -^bb1(%arg1: !pdl.operation): - %0 = transform.structured.match ops{["arith.addi"]} in %arg1 : (!pdl.operation) -> !pdl.operation +^bb1(%arg1: !transform.any_op): + %0 = transform.structured.match ops{["arith.addi"]} in %arg1 : (!transform.any_op) -> !transform.any_op // expected-error @below {{could not find an 'scf.for' parent}} - %1 = transform.loop.get_parent_for %0 : (!pdl.operation) -> !transform.op<"scf.for"> + %1 = transform.loop.get_parent_for %0 : (!transform.any_op) -> !transform.op<"scf.for"> } // ----- @@ -104,10 +104,10 @@ } transform.sequence failures(propagate) { -^bb1(%arg1: !pdl.operation): - %0 = transform.structured.match ops{["arith.addi"]} in %arg1 : (!pdl.operation) -> !pdl.operation - %1 = transform.loop.get_parent_for %0 : (!pdl.operation) -> !transform.op<"scf.for"> - transform.loop.peel %1 : (!transform.op<"scf.for">) -> !pdl.operation +^bb1(%arg1: !transform.any_op): + %0 = transform.structured.match ops{["arith.addi"]} in %arg1 : (!transform.any_op) -> !transform.any_op + %1 = transform.loop.get_parent_for %0 : (!transform.any_op) -> !transform.op<"scf.for"> + transform.loop.peel %1 : (!transform.op<"scf.for">) -> !transform.any_op } // ----- @@ -137,12 +137,12 @@ } transform.sequence failures(propagate) { -^bb1(%arg1: !pdl.operation): - %0 = transform.structured.match ops{["arith.addf"]} in %arg1 : (!pdl.operation) -> !pdl.operation - %1 = transform.loop.get_parent_for %0 : (!pdl.operation) -> !transform.op<"scf.for"> - %2 = transform.loop.pipeline %1 : (!transform.op<"scf.for">) -> !pdl.operation +^bb1(%arg1: !transform.any_op): + %0 = transform.structured.match ops{["arith.addf"]} in %arg1 : (!transform.any_op) -> !transform.any_op + %1 = transform.loop.get_parent_for %0 : (!transform.any_op) -> !transform.op<"scf.for"> + %2 = transform.loop.pipeline %1 : (!transform.op<"scf.for">) -> !transform.any_op // Verify that the returned handle is usable. - transform.test_print_remark_at_operand %2, "transformed" : !pdl.operation + transform.test_print_remark_at_operand %2, "transformed" : !transform.any_op } // ----- @@ -161,9 +161,9 @@ } transform.sequence failures(propagate) { -^bb1(%arg1: !pdl.operation): - %0 = transform.structured.match ops{["arith.addi"]} in %arg1 : (!pdl.operation) -> !pdl.operation - %1 = transform.loop.get_parent_for %0 : (!pdl.operation) -> !transform.op<"scf.for"> +^bb1(%arg1: !transform.any_op): + %0 = transform.structured.match ops{["arith.addi"]} in %arg1 : (!transform.any_op) -> !transform.any_op + %1 = transform.loop.get_parent_for %0 : (!transform.any_op) -> !transform.op<"scf.for"> transform.loop.unroll %1 { factor = 4 } : !transform.op<"scf.for"> } @@ -185,12 +185,12 @@ } transform.sequence failures(propagate) { -^bb1(%arg1: !pdl.operation): - %0 = transform.structured.match ops{["arith.addi"]} in %arg1 : (!pdl.operation) -> !pdl.operation +^bb1(%arg1: !transform.any_op): + %0 = transform.structured.match ops{["arith.addi"]} in %arg1 : (!transform.any_op) -> !transform.any_op // CHECK: = transform.loop.get_parent_for - %1 = transform.loop.get_parent_for %0 { affine = true } : (!pdl.operation) -> !transform.op<"affine.for"> - %2 = transform.loop.get_parent_for %0 { num_loops = 2, affine = true } : (!pdl.operation) -> !transform.op<"affine.for"> - %3 = transform.loop.get_parent_for %0 { num_loops = 3, affine = true } : (!pdl.operation) -> !transform.op<"affine.for"> + %1 = transform.loop.get_parent_for %0 { affine = true } : (!transform.any_op) -> !transform.op<"affine.for"> + %2 = transform.loop.get_parent_for %0 { num_loops = 2, affine = true } : (!transform.any_op) -> !transform.op<"affine.for"> + %3 = transform.loop.get_parent_for %0 { num_loops = 3, affine = true } : (!transform.any_op) -> !transform.op<"affine.for"> transform.test_print_remark_at_operand %1, "third loop" : !transform.op<"affine.for"> transform.test_print_remark_at_operand %2, "second loop" : !transform.op<"affine.for"> transform.test_print_remark_at_operand %3, "first loop" : !transform.op<"affine.for"> @@ -205,10 +205,10 @@ } transform.sequence failures(propagate) { -^bb1(%arg1: !pdl.operation): - %0 = transform.structured.match ops{["arith.addi"]} in %arg1 : (!pdl.operation) -> !pdl.operation +^bb1(%arg1: !transform.any_op): + %0 = transform.structured.match ops{["arith.addi"]} in %arg1 : (!transform.any_op) -> !transform.any_op // expected-error @below {{could not find an 'affine.for' parent}} - %1 = transform.loop.get_parent_for %0 { affine = true } : (!pdl.operation) -> !transform.op<"affine.for"> + %1 = transform.loop.get_parent_for %0 { affine = true } : (!transform.any_op) -> !transform.op<"affine.for"> } // ----- @@ -227,9 +227,9 @@ } transform.sequence failures(propagate) { -^bb1(%arg1: !pdl.operation): - %0 = transform.structured.match ops{["arith.addi"]} in %arg1 : (!pdl.operation) -> !pdl.operation - %1 = transform.loop.get_parent_for %0 { affine = true } : (!pdl.operation) -> !transform.op<"affine.for"> +^bb1(%arg1: !transform.any_op): + %0 = transform.structured.match ops{["arith.addi"]} in %arg1 : (!transform.any_op) -> !transform.any_op + %1 = transform.loop.get_parent_for %0 { affine = true } : (!transform.any_op) -> !transform.op<"affine.for"> transform.test_print_remark_at_operand %1, "affine for loop" : !transform.op<"affine.for"> transform.loop.unroll %1 { factor = 4, affine = true } : !transform.op<"affine.for"> } @@ -252,9 +252,9 @@ } transform.sequence failures(propagate) { -^bb1(%arg1: !pdl.operation): - %0 = transform.structured.match ops{["arith.addi"]} in %arg1 : (!pdl.operation) -> !pdl.operation - %1 = transform.loop.get_parent_for %0 { num_loops = 1, affine = true } : (!pdl.operation) -> !transform.op<"affine.for"> +^bb1(%arg1: !transform.any_op): + %0 = transform.structured.match ops{["arith.addi"]} in %arg1 : (!transform.any_op) -> !transform.any_op + %1 = transform.loop.get_parent_for %0 { num_loops = 1, affine = true } : (!transform.any_op) -> !transform.op<"affine.for"> transform.test_print_remark_at_operand %1, "affine for loop" : !transform.op<"affine.for"> transform.loop.unroll %1 { factor = 4 } : !transform.op<"affine.for"> } diff --git a/mlir/test/Dialect/Vector/vector-broadcast-lowering-transforms.mlir b/mlir/test/Dialect/Vector/vector-broadcast-lowering-transforms.mlir --- a/mlir/test/Dialect/Vector/vector-broadcast-lowering-transforms.mlir +++ b/mlir/test/Dialect/Vector/vector-broadcast-lowering-transforms.mlir @@ -163,10 +163,10 @@ } transform.sequence failures(propagate) { -^bb1(%module_op: !pdl.operation): +^bb1(%module_op: !transform.any_op): %f = transform.structured.match ops{["func.func"]} in %module_op - : (!pdl.operation) -> !pdl.operation + : (!transform.any_op) -> !transform.any_op transform.vector.lower_broadcast %f - : (!pdl.operation) -> !pdl.operation + : (!transform.any_op) -> !transform.any_op } diff --git a/mlir/test/Dialect/Vector/vector-contract-matvec-transforms.mlir b/mlir/test/Dialect/Vector/vector-contract-matvec-transforms.mlir --- a/mlir/test/Dialect/Vector/vector-contract-matvec-transforms.mlir +++ b/mlir/test/Dialect/Vector/vector-contract-matvec-transforms.mlir @@ -209,8 +209,8 @@ } transform.sequence failures(propagate) { -^bb1(%module_op: !pdl.operation): +^bb1(%module_op: !transform.any_op): transform.vector.lower_contraction %module_op lowering_strategy = "outerproduct" - : (!pdl.operation) -> !pdl.operation + : (!transform.any_op) -> !transform.any_op } diff --git a/mlir/test/Dialect/Vector/vector-contract-to-dot-transforms.mlir b/mlir/test/Dialect/Vector/vector-contract-to-dot-transforms.mlir --- a/mlir/test/Dialect/Vector/vector-contract-to-dot-transforms.mlir +++ b/mlir/test/Dialect/Vector/vector-contract-to-dot-transforms.mlir @@ -296,11 +296,11 @@ } transform.sequence failures(propagate) { -^bb1(%module_op: !pdl.operation): +^bb1(%module_op: !transform.any_op): %f = transform.structured.match ops{["func.func"]} in %module_op - : (!pdl.operation) -> !pdl.operation + : (!transform.any_op) -> !transform.any_op %f2 = transform.vector.lower_contraction %f lowering_strategy = "dot" - : (!pdl.operation) -> !pdl.operation + : (!transform.any_op) -> !transform.any_op } diff --git a/mlir/test/Dialect/Vector/vector-contract-to-matrix-intrinsics-transforms.mlir b/mlir/test/Dialect/Vector/vector-contract-to-matrix-intrinsics-transforms.mlir --- a/mlir/test/Dialect/Vector/vector-contract-to-matrix-intrinsics-transforms.mlir +++ b/mlir/test/Dialect/Vector/vector-contract-to-matrix-intrinsics-transforms.mlir @@ -44,14 +44,14 @@ } transform.sequence failures(propagate) { -^bb1(%module_op: !pdl.operation): +^bb1(%module_op: !transform.any_op): %f = transform.structured.match ops{["func.func"]} in %module_op - : (!pdl.operation) -> !pdl.operation + : (!transform.any_op) -> !transform.any_op %f2 = transform.vector.lower_contraction %f lowering_strategy = "matmulintrinsics" - : (!pdl.operation) -> !pdl.operation + : (!transform.any_op) -> !transform.any_op %f3 = transform.vector.lower_shape_cast %f2 - : (!pdl.operation) -> !pdl.operation + : (!transform.any_op) -> !transform.any_op } diff --git a/mlir/test/Dialect/Vector/vector-contract-to-outerproduct-transforms.mlir b/mlir/test/Dialect/Vector/vector-contract-to-outerproduct-transforms.mlir --- a/mlir/test/Dialect/Vector/vector-contract-to-outerproduct-transforms.mlir +++ b/mlir/test/Dialect/Vector/vector-contract-to-outerproduct-transforms.mlir @@ -343,11 +343,11 @@ transform.sequence failures(propagate) { -^bb1(%module_op: !pdl.operation): +^bb1(%module_op: !transform.any_op): %f = transform.structured.match ops{["func.func"]} in %module_op - : (!pdl.operation) -> !pdl.operation + : (!transform.any_op) -> !transform.any_op %f2 = transform.vector.lower_contraction %f lowering_strategy = "outerproduct" - : (!pdl.operation) -> !pdl.operation + : (!transform.any_op) -> !transform.any_op } diff --git a/mlir/test/Dialect/Vector/vector-contract-to-parallel-arith-transforms.mlir b/mlir/test/Dialect/Vector/vector-contract-to-parallel-arith-transforms.mlir --- a/mlir/test/Dialect/Vector/vector-contract-to-parallel-arith-transforms.mlir +++ b/mlir/test/Dialect/Vector/vector-contract-to-parallel-arith-transforms.mlir @@ -52,11 +52,11 @@ } transform.sequence failures(propagate) { -^bb1(%module_op: !pdl.operation): +^bb1(%module_op: !transform.any_op): %f = transform.structured.match ops{["func.func"]} in %module_op - : (!pdl.operation) -> !pdl.operation + : (!transform.any_op) -> !transform.any_op %f2 = transform.vector.lower_contraction %f lowering_strategy = "parallelarith" - : (!pdl.operation) -> !pdl.operation + : (!transform.any_op) -> !transform.any_op } diff --git a/mlir/test/Dialect/Vector/vector-mask-lowering-transforms.mlir b/mlir/test/Dialect/Vector/vector-mask-lowering-transforms.mlir --- a/mlir/test/Dialect/Vector/vector-mask-lowering-transforms.mlir +++ b/mlir/test/Dialect/Vector/vector-mask-lowering-transforms.mlir @@ -92,12 +92,12 @@ } transform.sequence failures(propagate) { -^bb1(%module_op: !pdl.operation): +^bb1(%module_op: !transform.any_op): %f = transform.structured.match ops{["func.func"]} in %module_op - : (!pdl.operation) -> !pdl.operation + : (!transform.any_op) -> !transform.any_op transform.vector.lower_masks %f - : (!pdl.operation) -> !pdl.operation + : (!transform.any_op) -> !transform.any_op } // ----- @@ -122,10 +122,10 @@ } transform.sequence failures(propagate) { -^bb1(%module_op: !pdl.operation): +^bb1(%module_op: !transform.any_op): %f = transform.structured.match ops{["func.func"]} in %module_op - : (!pdl.operation) -> !pdl.operation + : (!transform.any_op) -> !transform.any_op transform.vector.lower_masked_transfers %f - : (!pdl.operation) -> !pdl.operation + : (!transform.any_op) -> !transform.any_op } diff --git a/mlir/test/Dialect/Vector/vector-multi-reduction-lowering.mlir b/mlir/test/Dialect/Vector/vector-multi-reduction-lowering.mlir --- a/mlir/test/Dialect/Vector/vector-multi-reduction-lowering.mlir +++ b/mlir/test/Dialect/Vector/vector-multi-reduction-lowering.mlir @@ -266,8 +266,8 @@ // CHECK: vector.transpose %[[INPUT]], [1, 0, 2] : vector<3x4x5xf32> to vector<4x3x5xf32> transform.sequence failures(propagate) { -^bb1(%module_op: !pdl.operation): +^bb1(%module_op: !transform.any_op): transform.vector.lower_multi_reduction %module_op lowering_strategy = "innerreduction" - : (!pdl.operation) -> !pdl.operation + : (!transform.any_op) -> !transform.any_op } diff --git a/mlir/test/Dialect/Vector/vector-multi-reduction-outer-lowering.mlir b/mlir/test/Dialect/Vector/vector-multi-reduction-outer-lowering.mlir --- a/mlir/test/Dialect/Vector/vector-multi-reduction-outer-lowering.mlir +++ b/mlir/test/Dialect/Vector/vector-multi-reduction-outer-lowering.mlir @@ -189,8 +189,8 @@ // CHECK: return %{{.+}} transform.sequence failures(propagate) { -^bb1(%module_op: !pdl.operation): +^bb1(%module_op: !transform.any_op): transform.vector.lower_multi_reduction %module_op lowering_strategy = "innerparallel" - : (!pdl.operation) -> !pdl.operation + : (!transform.any_op) -> !transform.any_op } diff --git a/mlir/test/Dialect/Vector/vector-outerproduct-lowering-transforms.mlir b/mlir/test/Dialect/Vector/vector-outerproduct-lowering-transforms.mlir --- a/mlir/test/Dialect/Vector/vector-outerproduct-lowering-transforms.mlir +++ b/mlir/test/Dialect/Vector/vector-outerproduct-lowering-transforms.mlir @@ -136,13 +136,13 @@ } transform.sequence failures(propagate) { -^bb1(%module_op: !pdl.operation): +^bb1(%module_op: !transform.any_op): %f = transform.structured.match ops{["func.func"]} in %module_op - : (!pdl.operation) -> !pdl.operation + : (!transform.any_op) -> !transform.any_op %f2 = transform.vector.lower_outerproduct %f - : (!pdl.operation) -> !pdl.operation + : (!transform.any_op) -> !transform.any_op %f3 = transform.vector.lower_broadcast %f2 - : (!pdl.operation) -> !pdl.operation + : (!transform.any_op) -> !transform.any_op } diff --git a/mlir/test/Dialect/Vector/vector-shape-cast-lowering-transforms.mlir b/mlir/test/Dialect/Vector/vector-shape-cast-lowering-transforms.mlir --- a/mlir/test/Dialect/Vector/vector-shape-cast-lowering-transforms.mlir +++ b/mlir/test/Dialect/Vector/vector-shape-cast-lowering-transforms.mlir @@ -125,10 +125,10 @@ } transform.sequence failures(propagate) { -^bb1(%module_op: !pdl.operation): +^bb1(%module_op: !transform.any_op): %f = transform.structured.match ops{["func.func"]} in %module_op - : (!pdl.operation) -> !pdl.operation + : (!transform.any_op) -> !transform.any_op %f2 = transform.vector.lower_shape_cast %f - : (!pdl.operation) -> !pdl.operation + : (!transform.any_op) -> !transform.any_op } diff --git a/mlir/test/Dialect/Vector/vector-transfer-drop-unit-dims-patterns.mlir b/mlir/test/Dialect/Vector/vector-transfer-drop-unit-dims-patterns.mlir --- a/mlir/test/Dialect/Vector/vector-transfer-drop-unit-dims-patterns.mlir +++ b/mlir/test/Dialect/Vector/vector-transfer-drop-unit-dims-patterns.mlir @@ -30,7 +30,7 @@ transform.sequence failures(propagate) { -^bb1(%module_op: !pdl.operation): +^bb1(%module_op: !transform.any_op): transform.vector.apply_rank_reducing_subview_patterns %module_op - : (!pdl.operation) -> !pdl.operation + : (!transform.any_op) -> !transform.any_op } diff --git a/mlir/test/Dialect/Vector/vector-transfer-full-partial-split-copy-transform.mlir b/mlir/test/Dialect/Vector/vector-transfer-full-partial-split-copy-transform.mlir --- a/mlir/test/Dialect/Vector/vector-transfer-full-partial-split-copy-transform.mlir +++ b/mlir/test/Dialect/Vector/vector-transfer-full-partial-split-copy-transform.mlir @@ -107,10 +107,10 @@ } transform.sequence failures(propagate) { -^bb1(%module_op: !pdl.operation): +^bb1(%module_op: !transform.any_op): transform.vector.split_transfer_full_partial %module_op split_transfer_strategy = "linalg-copy" - : (!pdl.operation) -> !pdl.operation + : (!transform.any_op) -> !transform.any_op } // ----- @@ -168,10 +168,10 @@ // CHECK: } transform.sequence failures(propagate) { -^bb1(%module_op: !pdl.operation): +^bb1(%module_op: !transform.any_op): transform.vector.split_transfer_full_partial %module_op split_transfer_strategy = "linalg-copy" - : (!pdl.operation) -> !pdl.operation + : (!transform.any_op) -> !transform.any_op } // ----- @@ -236,8 +236,8 @@ // CHECK: } transform.sequence failures(propagate) { -^bb1(%module_op: !pdl.operation): +^bb1(%module_op: !transform.any_op): transform.vector.split_transfer_full_partial %module_op split_transfer_strategy = "linalg-copy" - : (!pdl.operation) -> !pdl.operation + : (!transform.any_op) -> !transform.any_op } diff --git a/mlir/test/Dialect/Vector/vector-transfer-full-partial-split.mlir b/mlir/test/Dialect/Vector/vector-transfer-full-partial-split.mlir --- a/mlir/test/Dialect/Vector/vector-transfer-full-partial-split.mlir +++ b/mlir/test/Dialect/Vector/vector-transfer-full-partial-split.mlir @@ -102,10 +102,10 @@ } transform.sequence failures(propagate) { -^bb1(%module_op: !pdl.operation): +^bb1(%module_op: !transform.any_op): transform.vector.split_transfer_full_partial %module_op split_transfer_strategy = "vector-transfer" - : (!pdl.operation) -> !pdl.operation + : (!transform.any_op) -> !transform.any_op } // ----- @@ -160,10 +160,10 @@ transform.sequence failures(propagate) { -^bb1(%module_op: !pdl.operation): +^bb1(%module_op: !transform.any_op): transform.vector.split_transfer_full_partial %module_op split_transfer_strategy = "vector-transfer" - : (!pdl.operation) -> !pdl.operation + : (!transform.any_op) -> !transform.any_op } // ----- @@ -222,10 +222,10 @@ // CHECK: } transform.sequence failures(propagate) { -^bb1(%module_op: !pdl.operation): +^bb1(%module_op: !transform.any_op): transform.vector.split_transfer_full_partial %module_op split_transfer_strategy = "vector-transfer" - : (!pdl.operation) -> !pdl.operation + : (!transform.any_op) -> !transform.any_op } // ----- @@ -264,8 +264,8 @@ } transform.sequence failures(propagate) { -^bb1(%module_op: !pdl.operation): +^bb1(%module_op: !transform.any_op): transform.vector.split_transfer_full_partial %module_op split_transfer_strategy = "vector-transfer" - : (!pdl.operation) -> !pdl.operation + : (!transform.any_op) -> !transform.any_op } diff --git a/mlir/test/Dialect/Vector/vector-transfer-to-vector-load-store.mlir b/mlir/test/Dialect/Vector/vector-transfer-to-vector-load-store.mlir --- a/mlir/test/Dialect/Vector/vector-transfer-to-vector-load-store.mlir +++ b/mlir/test/Dialect/Vector/vector-transfer-to-vector-load-store.mlir @@ -239,12 +239,12 @@ transform.sequence failures(propagate) { -^bb1(%module_op: !pdl.operation): +^bb1(%module_op: !transform.any_op): %m2 = transform.vector.lower_transfer %module_op max_transfer_rank = 99 - : (!pdl.operation) -> !pdl.operation + : (!transform.any_op) -> !transform.any_op transform.vector.apply_transfer_permutation_patterns %m2 - : (!pdl.operation) -> !pdl.operation + : (!transform.any_op) -> !transform.any_op } // ----- @@ -362,10 +362,10 @@ } transform.sequence failures(propagate) { -^bb1(%module_op: !pdl.operation): +^bb1(%module_op: !transform.any_op): %m2 = transform.vector.lower_transfer %module_op max_transfer_rank = 99 - : (!pdl.operation) -> !pdl.operation + : (!transform.any_op) -> !transform.any_op transform.vector.apply_transfer_permutation_patterns %m2 - : (!pdl.operation) -> !pdl.operation + : (!transform.any_op) -> !transform.any_op } diff --git a/mlir/test/Dialect/Vector/vector-transpose-lowering.mlir b/mlir/test/Dialect/Vector/vector-transpose-lowering.mlir --- a/mlir/test/Dialect/Vector/vector-transpose-lowering.mlir +++ b/mlir/test/Dialect/Vector/vector-transpose-lowering.mlir @@ -75,10 +75,10 @@ } transform.sequence failures(propagate) { -^bb1(%module_op: !pdl.operation): +^bb1(%module_op: !transform.any_op): transform.vector.lower_transpose %module_op lowering_strategy = "eltwise" - : (!pdl.operation) -> !pdl.operation + : (!transform.any_op) -> !transform.any_op } // ----- @@ -98,10 +98,10 @@ transform.sequence failures(propagate) { -^bb1(%module_op: !pdl.operation): +^bb1(%module_op: !transform.any_op): transform.vector.lower_transpose %module_op lowering_strategy = "shuffle_1d" - : (!pdl.operation) -> !pdl.operation + : (!transform.any_op) -> !transform.any_op } // ----- @@ -117,10 +117,10 @@ transform.sequence failures(propagate) { -^bb1(%module_op: !pdl.operation): +^bb1(%module_op: !transform.any_op): transform.vector.lower_transpose %module_op lowering_strategy = "flat_transpose" - : (!pdl.operation) -> !pdl.operation + : (!transform.any_op) -> !transform.any_op } // ----- @@ -604,10 +604,10 @@ } transform.sequence failures(propagate) { -^bb1(%module_op: !pdl.operation): +^bb1(%module_op: !transform.any_op): transform.vector.lower_transpose %module_op avx2_lowering_strategy = true - : (!pdl.operation) -> !pdl.operation + : (!transform.any_op) -> !transform.any_op } // ----- @@ -682,10 +682,10 @@ } transform.sequence failures(propagate) { -^bb1(%module_op: !pdl.operation): +^bb1(%module_op: !transform.any_op): transform.vector.lower_transpose %module_op lowering_strategy = "shuffle_16x16" - : (!pdl.operation) -> !pdl.operation + : (!transform.any_op) -> !transform.any_op } // ----- @@ -761,8 +761,8 @@ } transform.sequence failures(propagate) { -^bb1(%module_op: !pdl.operation): +^bb1(%module_op: !transform.any_op): transform.vector.lower_transpose %module_op lowering_strategy = "shuffle_16x16" - : (!pdl.operation) -> !pdl.operation + : (!transform.any_op) -> !transform.any_op } diff --git a/mlir/test/Integration/Dialect/Linalg/CPU/test-conv-1d-call.mlir b/mlir/test/Integration/Dialect/Linalg/CPU/test-conv-1d-call.mlir --- a/mlir/test/Integration/Dialect/Linalg/CPU/test-conv-1d-call.mlir +++ b/mlir/test/Integration/Dialect/Linalg/CPU/test-conv-1d-call.mlir @@ -25,9 +25,9 @@ } transform.sequence failures(propagate) { - ^bb0(%arg1: !pdl.operation): - %0 = transform.structured.match ops{["linalg.conv_1d"]} in %arg1 : (!pdl.operation) -> !pdl.operation - %1, %loop = transform.structured.tile %0 [4] : (!pdl.operation) -> (!pdl.operation, !pdl.operation) + ^bb0(%arg1: !transform.any_op): + %0 = transform.structured.match ops{["linalg.conv_1d"]} in %arg1 : (!transform.any_op) -> !transform.any_op + %1, %loop = transform.structured.tile %0 [4] : (!transform.any_op) -> (!transform.any_op, !transform.any_op) } func.func @main() { diff --git a/mlir/test/Integration/Dialect/Linalg/CPU/test-conv-1d-nwc-wcf-call.mlir b/mlir/test/Integration/Dialect/Linalg/CPU/test-conv-1d-nwc-wcf-call.mlir --- a/mlir/test/Integration/Dialect/Linalg/CPU/test-conv-1d-nwc-wcf-call.mlir +++ b/mlir/test/Integration/Dialect/Linalg/CPU/test-conv-1d-nwc-wcf-call.mlir @@ -27,9 +27,9 @@ } transform.sequence failures(propagate) { - ^bb0(%arg1: !pdl.operation): - %0 = transform.structured.match ops{["linalg.conv_1d_nwc_wcf"]} in %arg1 : (!pdl.operation) -> !pdl.operation - %1, %loops:2 = transform.structured.tile %0 [2, 4] : (!pdl.operation) -> (!pdl.operation, !pdl.operation, !pdl.operation) + ^bb0(%arg1: !transform.any_op): + %0 = transform.structured.match ops{["linalg.conv_1d_nwc_wcf"]} in %arg1 : (!transform.any_op) -> !transform.any_op + %1, %loops:2 = transform.structured.tile %0 [2, 4] : (!transform.any_op) -> (!transform.any_op, !transform.any_op, !transform.any_op) } func.func @main() { diff --git a/mlir/test/Integration/Dialect/Linalg/CPU/test-conv-2d-call.mlir b/mlir/test/Integration/Dialect/Linalg/CPU/test-conv-2d-call.mlir --- a/mlir/test/Integration/Dialect/Linalg/CPU/test-conv-2d-call.mlir +++ b/mlir/test/Integration/Dialect/Linalg/CPU/test-conv-2d-call.mlir @@ -25,9 +25,9 @@ } transform.sequence failures(propagate) { - ^bb0(%arg1: !pdl.operation): - %0 = transform.structured.match ops{["linalg.conv_2d"]} in %arg1 : (!pdl.operation) -> !pdl.operation - %1, %loops:2 = transform.structured.tile %0 [2, 2] : (!pdl.operation) -> (!pdl.operation, !pdl.operation, !pdl.operation) + ^bb0(%arg1: !transform.any_op): + %0 = transform.structured.match ops{["linalg.conv_2d"]} in %arg1 : (!transform.any_op) -> !transform.any_op + %1, %loops:2 = transform.structured.tile %0 [2, 2] : (!transform.any_op) -> (!transform.any_op, !transform.any_op, !transform.any_op) } func.func @main() { diff --git a/mlir/test/Integration/Dialect/Linalg/CPU/test-conv-2d-nhwc-hwcf-call.mlir b/mlir/test/Integration/Dialect/Linalg/CPU/test-conv-2d-nhwc-hwcf-call.mlir --- a/mlir/test/Integration/Dialect/Linalg/CPU/test-conv-2d-nhwc-hwcf-call.mlir +++ b/mlir/test/Integration/Dialect/Linalg/CPU/test-conv-2d-nhwc-hwcf-call.mlir @@ -27,9 +27,9 @@ } transform.sequence failures(propagate) { - ^bb0(%arg1: !pdl.operation): - %0 = transform.structured.match ops{["linalg.conv_2d_nhwc_hwcf"]} in %arg1 : (!pdl.operation) -> !pdl.operation - %1, %loops:4 = transform.structured.tile %0 [2, 3, 3, 2] : (!pdl.operation) -> (!pdl.operation, !pdl.operation, !pdl.operation, !pdl.operation, !pdl.operation) + ^bb0(%arg1: !transform.any_op): + %0 = transform.structured.match ops{["linalg.conv_2d_nhwc_hwcf"]} in %arg1 : (!transform.any_op) -> !transform.any_op + %1, %loops:4 = transform.structured.tile %0 [2, 3, 3, 2] : (!transform.any_op) -> (!transform.any_op, !transform.any_op, !transform.any_op, !transform.any_op, !transform.any_op) } func.func @main() { diff --git a/mlir/test/Integration/Dialect/Linalg/CPU/test-conv-3d-call.mlir b/mlir/test/Integration/Dialect/Linalg/CPU/test-conv-3d-call.mlir --- a/mlir/test/Integration/Dialect/Linalg/CPU/test-conv-3d-call.mlir +++ b/mlir/test/Integration/Dialect/Linalg/CPU/test-conv-3d-call.mlir @@ -25,9 +25,9 @@ } transform.sequence failures(propagate) { - ^bb0(%arg1: !pdl.operation): - %0 = transform.structured.match ops{["linalg.conv_3d"]} in %arg1 : (!pdl.operation) -> !pdl.operation - %1, %loops:3 = transform.structured.tile %0 [2, 2, 2] : (!pdl.operation) -> (!pdl.operation, !pdl.operation, !pdl.operation, !pdl.operation) + ^bb0(%arg1: !transform.any_op): + %0 = transform.structured.match ops{["linalg.conv_3d"]} in %arg1 : (!transform.any_op) -> !transform.any_op + %1, %loops:3 = transform.structured.tile %0 [2, 2, 2] : (!transform.any_op) -> (!transform.any_op, !transform.any_op, !transform.any_op, !transform.any_op) } func.func @main() { diff --git a/mlir/test/Integration/Dialect/Linalg/CPU/test-conv-3d-ndhwc-dhwcf-call.mlir b/mlir/test/Integration/Dialect/Linalg/CPU/test-conv-3d-ndhwc-dhwcf-call.mlir --- a/mlir/test/Integration/Dialect/Linalg/CPU/test-conv-3d-ndhwc-dhwcf-call.mlir +++ b/mlir/test/Integration/Dialect/Linalg/CPU/test-conv-3d-ndhwc-dhwcf-call.mlir @@ -27,9 +27,9 @@ } transform.sequence failures(propagate) { - ^bb0(%arg1: !pdl.operation): - %0 = transform.structured.match ops{["linalg.conv_3d_ndhwc_dhwcf"]} in %arg1 : (!pdl.operation) -> !pdl.operation - %1, %loops:3 = transform.structured.tile %0 [0, 5, 5, 5] : (!pdl.operation) -> (!pdl.operation, !pdl.operation, !pdl.operation, !pdl.operation) + ^bb0(%arg1: !transform.any_op): + %0 = transform.structured.match ops{["linalg.conv_3d_ndhwc_dhwcf"]} in %arg1 : (!transform.any_op) -> !transform.any_op + %1, %loops:3 = transform.structured.tile %0 [0, 5, 5, 5] : (!transform.any_op) -> (!transform.any_op, !transform.any_op, !transform.any_op, !transform.any_op) } func.func @main() { diff --git a/mlir/test/Integration/Dialect/Linalg/CPU/test-tensor-matmul.mlir b/mlir/test/Integration/Dialect/Linalg/CPU/test-tensor-matmul.mlir --- a/mlir/test/Integration/Dialect/Linalg/CPU/test-tensor-matmul.mlir +++ b/mlir/test/Integration/Dialect/Linalg/CPU/test-tensor-matmul.mlir @@ -37,9 +37,9 @@ } transform.sequence failures(propagate) { - ^bb0(%arg1: !pdl.operation): - %0 = transform.structured.match ops{["linalg.matmul"]} in %arg1 : (!pdl.operation) -> !pdl.operation - %1, %loops:3 = transform.structured.tile %0 [1, 2, 3] : (!pdl.operation) -> (!pdl.operation, !pdl.operation, !pdl.operation, !pdl.operation) + ^bb0(%arg1: !transform.any_op): + %0 = transform.structured.match ops{["linalg.matmul"]} in %arg1 : (!transform.any_op) -> !transform.any_op + %1, %loops:3 = transform.structured.tile %0 [1, 2, 3] : (!transform.any_op) -> (!transform.any_op, !transform.any_op, !transform.any_op, !transform.any_op) } func.func private @printMemrefF32(%ptr : tensor<*xf32>) diff --git a/mlir/test/python/dialects/transform.py b/mlir/test/python/dialects/transform.py --- a/mlir/test/python/dialects/transform.py +++ b/mlir/test/python/dialects/transform.py @@ -32,38 +32,38 @@ @run def testSequenceOp(): sequence = transform.SequenceOp(transform.FailurePropagationMode.PROPAGATE, - [pdl.OperationType.get()], - pdl.OperationType.get()) + [transform.AnyOpType.get()], + transform.AnyOpType.get()) with InsertionPoint(sequence.body): transform.YieldOp([sequence.bodyTarget]) # CHECK-LABEL: TEST: testSequenceOp - # CHECK: = transform.sequence -> !pdl.operation failures(propagate) { - # CHECK: ^{{.*}}(%[[ARG0:.+]]: !pdl.operation): - # CHECK: yield %[[ARG0]] : !pdl.operation + # CHECK: = transform.sequence -> !transform.any_op failures(propagate) { + # CHECK: ^{{.*}}(%[[ARG0:.+]]: !transform.any_op): + # CHECK: yield %[[ARG0]] : !transform.any_op # CHECK: } @run def testNestedSequenceOp(): - sequence = transform.SequenceOp(transform.FailurePropagationMode.PROPAGATE, [], pdl.OperationType.get()) + sequence = transform.SequenceOp(transform.FailurePropagationMode.PROPAGATE, [], transform.AnyOpType.get()) with InsertionPoint(sequence.body): nested = transform.SequenceOp(transform.FailurePropagationMode.PROPAGATE, [], sequence.bodyTarget) with InsertionPoint(nested.body): doubly_nested = transform.SequenceOp( transform.FailurePropagationMode.PROPAGATE, - [pdl.OperationType.get()], nested.bodyTarget) + [transform.AnyOpType.get()], nested.bodyTarget) with InsertionPoint(doubly_nested.body): transform.YieldOp([doubly_nested.bodyTarget]) transform.YieldOp() transform.YieldOp() # CHECK-LABEL: TEST: testNestedSequenceOp # CHECK: transform.sequence failures(propagate) { - # CHECK: ^{{.*}}(%[[ARG0:.+]]: !pdl.operation): - # CHECK: sequence %[[ARG0]] : !pdl.operation failures(propagate) { - # CHECK: ^{{.*}}(%[[ARG1:.+]]: !pdl.operation): - # CHECK: = sequence %[[ARG1]] : !pdl.operation -> !pdl.operation failures(propagate) { - # CHECK: ^{{.*}}(%[[ARG2:.+]]: !pdl.operation): - # CHECK: yield %[[ARG2]] : !pdl.operation + # CHECK: ^{{.*}}(%[[ARG0:.+]]: !transform.any_op): + # CHECK: sequence %[[ARG0]] : !transform.any_op failures(propagate) { + # CHECK: ^{{.*}}(%[[ARG1:.+]]: !transform.any_op): + # CHECK: = sequence %[[ARG1]] : !transform.any_op -> !transform.any_op failures(propagate) { + # CHECK: ^{{.*}}(%[[ARG2:.+]]: !transform.any_op): + # CHECK: yield %[[ARG2]] : !transform.any_op # CHECK: } # CHECK: } # CHECK: } @@ -103,58 +103,58 @@ @run def testTransformPDLOps(): - withPdl = transform.WithPDLPatternsOp(pdl.OperationType.get()) + withPdl = transform.WithPDLPatternsOp(transform.AnyOpType.get()) with InsertionPoint(withPdl.body): sequence = transform.SequenceOp(transform.FailurePropagationMode.PROPAGATE, - [pdl.OperationType.get()], + [transform.AnyOpType.get()], withPdl.bodyTarget) with InsertionPoint(sequence.body): - match = transform.PDLMatchOp(pdl.OperationType.get(), sequence.bodyTarget, "pdl_matcher") + match = transform.PDLMatchOp(transform.AnyOpType.get(), sequence.bodyTarget, "pdl_matcher") transform.YieldOp(match) # CHECK-LABEL: TEST: testTransformPDLOps # CHECK: transform.with_pdl_patterns { - # CHECK: ^{{.*}}(%[[ARG0:.+]]: !pdl.operation): - # CHECK: = sequence %[[ARG0]] : !pdl.operation -> !pdl.operation failures(propagate) { - # CHECK: ^{{.*}}(%[[ARG1:.+]]: !pdl.operation): + # CHECK: ^{{.*}}(%[[ARG0:.+]]: !transform.any_op): + # CHECK: = sequence %[[ARG0]] : !transform.any_op -> !transform.any_op failures(propagate) { + # CHECK: ^{{.*}}(%[[ARG1:.+]]: !transform.any_op): # CHECK: %[[RES:.+]] = pdl_match @pdl_matcher in %[[ARG1]] - # CHECK: yield %[[RES]] : !pdl.operation + # CHECK: yield %[[RES]] : !transform.any_op # CHECK: } # CHECK: } @run def testGetClosestIsolatedParentOp(): - sequence = transform.SequenceOp(transform.FailurePropagationMode.PROPAGATE, [], pdl.OperationType.get()) + sequence = transform.SequenceOp(transform.FailurePropagationMode.PROPAGATE, [], transform.AnyOpType.get()) with InsertionPoint(sequence.body): - transform.GetClosestIsolatedParentOp(pdl.OperationType.get(), sequence.bodyTarget) + transform.GetClosestIsolatedParentOp(transform.AnyOpType.get(), sequence.bodyTarget) transform.YieldOp() # CHECK-LABEL: TEST: testGetClosestIsolatedParentOp # CHECK: transform.sequence - # CHECK: ^{{.*}}(%[[ARG1:.+]]: !pdl.operation): + # CHECK: ^{{.*}}(%[[ARG1:.+]]: !transform.any_op): # CHECK: = get_closest_isolated_parent %[[ARG1]] @run def testMergeHandlesOp(): - sequence = transform.SequenceOp(transform.FailurePropagationMode.PROPAGATE, [], pdl.OperationType.get()) + sequence = transform.SequenceOp(transform.FailurePropagationMode.PROPAGATE, [], transform.AnyOpType.get()) with InsertionPoint(sequence.body): transform.MergeHandlesOp([sequence.bodyTarget]) transform.YieldOp() # CHECK-LABEL: TEST: testMergeHandlesOp # CHECK: transform.sequence - # CHECK: ^{{.*}}(%[[ARG1:.+]]: !pdl.operation): + # CHECK: ^{{.*}}(%[[ARG1:.+]]: !transform.any_op): # CHECK: = merge_handles %[[ARG1]] @run def testReplicateOp(): - with_pdl = transform.WithPDLPatternsOp(pdl.OperationType.get()) + with_pdl = transform.WithPDLPatternsOp(transform.AnyOpType.get()) with InsertionPoint(with_pdl.body): sequence = transform.SequenceOp( transform.FailurePropagationMode.PROPAGATE, [], with_pdl.bodyTarget) with InsertionPoint(sequence.body): - m1 = transform.PDLMatchOp(pdl.OperationType.get(), sequence.bodyTarget, "first") - m2 = transform.PDLMatchOp(pdl.OperationType.get(), sequence.bodyTarget, "second") + m1 = transform.PDLMatchOp(transform.AnyOpType.get(), sequence.bodyTarget, "first") + m2 = transform.PDLMatchOp(transform.AnyOpType.get(), sequence.bodyTarget, "second") transform.ReplicateOp(m1, [m2]) transform.YieldOp() # CHECK-LABEL: TEST: testReplicateOp