[Mlir-commits] [mlir] [mlir] Implement indexed access op interfaces for memref, vector, gpu, nvgpu (PR #177014)
Maksim Levental
llvmlistbot at llvm.org
Wed Jan 28 20:58:08 PST 2026
================
@@ -778,6 +780,13 @@ def MemRef_DmaStartOp : MemRef_Op<"dma_start"> {
return {(*this)->operand_begin() + 1,
(*this)->operand_begin() + 1 + getSrcMemRefRank()};
}
+ // Alias to getSrcMemRef() for uniformity with other DMA-like ops.
+ ::mlir::TypedValue<::mlir::MemRefType> getSrc() {
+ // This can be called before op verifaciton, so we guarad against bad variadics.
+ if ((*this)->getNumOperands() < 1)
----------------
makslevental wrote:
`this->getOperands().empty()`
https://github.com/llvm/llvm-project/pull/177014
More information about the Mlir-commits
mailing list