[Mlir-commits] [mlir] 5f5f71e - [mlir][tensor][bufferize] Load dependent dialects

Matthias Springer llvmlistbot at llvm.org
Mon Jul 25 02:39:43 PDT 2022


Author: Matthias Springer
Date: 2022-07-25T11:36:10+02:00
New Revision: 5f5f71e73768cb185beaccdca463bf772cf8d1b3

URL: https://github.com/llvm/llvm-project/commit/5f5f71e73768cb185beaccdca463bf772cf8d1b3
DIFF: https://github.com/llvm/llvm-project/commit/5f5f71e73768cb185beaccdca463bf772cf8d1b3.diff

LOG: [mlir][tensor][bufferize] Load dependent dialects

Load dialects that will be generated by the extension. (Except for BufferizationDialect and MemrefDialect which are loaded already.)

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

Added: 
    

Modified: 
    mlir/lib/Dialect/Tensor/Transforms/BufferizableOpInterfaceImpl.cpp

Removed: 
    


################################################################################
diff  --git a/mlir/lib/Dialect/Tensor/Transforms/BufferizableOpInterfaceImpl.cpp b/mlir/lib/Dialect/Tensor/Transforms/BufferizableOpInterfaceImpl.cpp
index 2916f1f2ef22..51bd6eb4db69 100644
--- a/mlir/lib/Dialect/Tensor/Transforms/BufferizableOpInterfaceImpl.cpp
+++ b/mlir/lib/Dialect/Tensor/Transforms/BufferizableOpInterfaceImpl.cpp
@@ -1063,5 +1063,8 @@ void mlir::tensor::registerBufferizableOpInterfaceExternalModels(
         *ctx);
     RankOp::attachInterface<RankOpInterface>(*ctx);
     ReshapeOp::attachInterface<ReshapeOpInterface>(*ctx);
+
+    // Load additional dialects of which ops may get created.
+    ctx->loadDialect<arith::ArithmeticDialect, scf::SCFDialect>();
   });
 }


        


More information about the Mlir-commits mailing list