[mlir][linalg][bufferize] Fix bug in getInplaceableOpResult

Differential Revision: https://reviews.llvm.org/D112123
This commit is contained in:
Matthias Springer 2021-10-21 21:54:54 +09:00
parent 7a7e93f122
commit 94213bc7de
1 changed files with 1 additions and 1 deletions

View File

@ -508,7 +508,7 @@ static OpResult getInplaceableOpResult(VectorTransferOpInterface op,
/// 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);
}