diff --git a/mlir/include/mlir/Dialect/MemRef/IR/MemRefOps.td b/mlir/include/mlir/Dialect/MemRef/IR/MemRefOps.td --- a/mlir/include/mlir/Dialect/MemRef/IR/MemRefOps.td +++ b/mlir/include/mlir/Dialect/MemRef/IR/MemRefOps.td @@ -902,6 +902,7 @@ DeclareOpInterfaceMethods, Pure, SameVariadicResultSize, + ViewLikeOpInterface, DeclareOpInterfaceMethods]> { let summary = "Extracts a buffer base with offset and strides"; let description = [{ @@ -976,6 +977,8 @@ SmallVector getConstifiedMixedStrides(); /// Similar to `getConstifiedMixedSizes` but for the offset. OpFoldResult getConstifiedMixedOffset(); + + ::mlir::Value getViewSource() { return getSource(); } }]; let hasFolder = 1; @@ -1016,7 +1019,7 @@ }]; let arguments = (ins - MemRefOf<[AnySignlessInteger, AnyFloat]>:$memref, + Arg, "the reference to read from and write to", [MemRead, MemWrite]>:$memref, Variadic:$indices); let results = (outs @@ -2250,7 +2253,7 @@ let arguments = (ins AtomicRMWKindAttr:$kind, AnyTypeOf<[AnySignlessInteger, AnyFloat]>:$value, - MemRefOf<[AnySignlessInteger, AnyFloat]>:$memref, + Arg, "the reference to read from and write to", [MemRead, MemWrite]>:$memref, Variadic:$indices); let results = (outs AnyTypeOf<[AnySignlessInteger, AnyFloat]>:$result);