diff --git a/mlir/lib/Dialect/Linalg/Transforms/ComprehensiveBufferize.cpp b/mlir/lib/Dialect/Linalg/Transforms/ComprehensiveBufferize.cpp --- a/mlir/lib/Dialect/Linalg/Transforms/ComprehensiveBufferize.cpp +++ b/mlir/lib/Dialect/Linalg/Transforms/ComprehensiveBufferize.cpp @@ -508,7 +508,7 @@ /// when the op is bufferized inplace. /// Return null if no such result exists. static OpResult getInplaceableOpResult(InsertSliceOp op, OpOperand &opOperand) { - if (opOperand.get() != op.dest()) + if (&opOperand != &op->getOpOperand(1) /*dest*/) return OpResult(); return op->getResult(0); }