[Mlir-commits] [mlir] [mlir][bufferization] Add `BufferizableOpInterface::hasTensorSemantics` (PR #75273)

Matthias Springer llvmlistbot at llvm.org
Fri Jan 5 06:55:58 PST 2024


================
@@ -458,6 +458,15 @@ LogicalResult mlir::bufferization::bufferizeModuleOp(
       foldMemRefCasts(funcOp);
   }
 
+  // Bufferize all other ops.
+  for (Operation &op : moduleOp.getOps()) {
+    // Functions were already bufferized.
+    if (isa<func::FuncOp>(&op))
----------------
matthias-springer wrote:

For consistency reasons, `func::FuncOp` would be better here. Other function-like ops are not supported at the moment (they will fail to bufferize) and we exclusively use `func::FuncOp`, `func::CallOp`, `func::ReturnOp` in this file at the moment.


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


More information about the Mlir-commits mailing list