[Mlir-commits] [mlir] [mlir][Hoisting] Hoisting vector.extract/vector.broadcast pairs (PR #86108)
Matthias Springer
llvmlistbot at llvm.org
Fri Apr 12 00:23:03 PDT 2024
================
@@ -2206,6 +2206,42 @@ def HoistRedundantVectorTransfersOp :
}];
}
+//===----------------------------------------------------------------------===//
+// HoistRedundantVectorBroadcastsOp
+//===----------------------------------------------------------------------===//
+
+def HoistRedundantVectorBroadcastsOp :
+ Op<Transform_Dialect, "structured.hoist_redundant_vector_broadcasts",
+ [FunctionalStyleTransformOpTrait, MemoryEffectsOpInterface,
+ TransformEachOpTrait, TransformOpInterface,
+ ReportTrackingListenerFailuresOpTrait]> {
+ let description = [{
+ Hoist vector.extract / vector.broadcasts pairs out of immediately
+ enclosing scf::ForOp iteratively.
+
+ #### Return modes:
+
+ The operation always succeeds and returns a handle to the transformed
+ function op.
+ }];
+
+ let arguments = (ins TransformHandleTypeInterface:$target);
+ let results = (outs TransformHandleTypeInterface:$transformed);
+
+ let assemblyFormat = "$target attr-dict `:` functional-type(operands, results) ";
+
+ let builders = [
+ OpBuilder<(ins "Value":$target)>,
+ ];
+ let extraClassDeclaration = [{
+ ::mlir::DiagnosedSilenceableFailure applyToOne(
+ ::mlir::transform::TransformRewriter &rewriter,
+ ::mlir::func::FuncOp target,
----------------
matthias-springer wrote:
can this be `Operation *`?
https://github.com/llvm/llvm-project/pull/86108
More information about the Mlir-commits
mailing list