[Mlir-commits] [mlir] The implementation would crash with unloaded dialects. (PR #108249)

llvmlistbot at llvm.org llvmlistbot at llvm.org
Wed Sep 11 09:56:35 PDT 2024


llvmbot wrote:


<!--LLVM PR SUMMARY COMMENT-->
@llvm/pr-subscribers-mlir-bufferization

@llvm/pr-subscribers-mlir

Author: Matteo Franciolini (mfrancio)

<details>
<summary>Changes</summary>

The implementation would crash with unloaded dialects.


---
Full diff: https://github.com/llvm/llvm-project/pull/108249.diff


1 Files Affected:

- (modified) mlir/include/mlir/Dialect/Bufferization/IR/BufferizableOpInterface.h (+1-1) 


``````````diff
diff --git a/mlir/include/mlir/Dialect/Bufferization/IR/BufferizableOpInterface.h b/mlir/include/mlir/Dialect/Bufferization/IR/BufferizableOpInterface.h
index 2fda091e412aef..aceb9d059b95f3 100644
--- a/mlir/include/mlir/Dialect/Bufferization/IR/BufferizableOpInterface.h
+++ b/mlir/include/mlir/Dialect/Bufferization/IR/BufferizableOpInterface.h
@@ -152,7 +152,7 @@ class OpFilter {
   /// This function adds a DENY entry.
   void denyDialect(StringRef dialectNamespace) {
     Entry::FilterFn filterFn = [=](Operation *op) {
-      return op->getDialect()->getNamespace() == dialectNamespace;
+      return op->getName().getDialectNamespace() == dialectNamespace;
     };
     entries.push_back(Entry{filterFn, Entry::FilterType::DENY});
   }

``````````

</details>


https://github.com/llvm/llvm-project/pull/108249


More information about the Mlir-commits mailing list