[Mlir-commits] [mlir] 980bb9b - [mlir][SCF][transform] Register SCF dialect patterns

Matthias Springer llvmlistbot at llvm.org
Mon Jun 5 02:42:30 PDT 2023


Author: Matthias Springer
Date: 2023-06-05T11:37:22+02:00
New Revision: 980bb9bd826a646199d032bc03e8e0054042a6e6

URL: https://github.com/llvm/llvm-project/commit/980bb9bd826a646199d032bc03e8e0054042a6e6
DIFF: https://github.com/llvm/llvm-project/commit/980bb9bd826a646199d032bc03e8e0054042a6e6.diff

LOG: [mlir][SCF][transform] Register SCF dialect patterns

Differential Revision: https://reviews.llvm.org/D152125

Added: 
    

Modified: 
    mlir/lib/Dialect/SCF/TransformOps/SCFTransformOps.cpp

Removed: 
    


################################################################################
diff  --git a/mlir/lib/Dialect/SCF/TransformOps/SCFTransformOps.cpp b/mlir/lib/Dialect/SCF/TransformOps/SCFTransformOps.cpp
index 2da7473bf6595..4c64c5420bf9e 100644
--- a/mlir/lib/Dialect/SCF/TransformOps/SCFTransformOps.cpp
+++ b/mlir/lib/Dialect/SCF/TransformOps/SCFTransformOps.cpp
@@ -309,6 +309,13 @@ class SCFTransformDialectExtension
 #define GET_OP_LIST
 #include "mlir/Dialect/SCF/TransformOps/SCFTransformOps.cpp.inc"
         >();
+
+    addDialectDataInitializer<transform::PatternRegistry>(
+        [&](transform::PatternRegistry &registry) {
+          registry.registerPatterns(
+              "scf.for_loop_canonicalization",
+              scf::populateSCFForLoopCanonicalizationPatterns);
+        });
   }
 };
 } // namespace


        


More information about the Mlir-commits mailing list