This revision will make it easier to create new ops base on the strided memref abstraction outside of the std dialect.
Details
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
Can you add proper documentation in the description+commit on what this interface is, how it is intended to be used, and what the invariants are?
mlir/include/mlir/Interfaces/ViewLikeInterface.td | ||
---|---|---|
35 | Please provide a much more detailed description here. It isn't clear what this is supposed to mean or how it should be used. | |
218 | The formatting on most of these is off, please fix it. |
mlir/include/mlir/Interfaces/ViewLikeInterface.h | ||
---|---|---|
22 | SubViewOp/SubTensorOp don't make sense to mention here. |
mlir/include/mlir/Interfaces/ViewLikeInterface.td | ||
---|---|---|
35 | Note: I am hoping to also provide reusable verification/parsing/printing. |
mlir/include/mlir/Interfaces/ViewLikeInterface.td | ||
---|---|---|
35 | Verification is common, there is a verify field on OpInterface where you can specify that and it will be placed on the generated interface trait class. For parsers/printers those are fine to provide as utilities, just not really on the interface class itself. I'd expose those in a impl namespace in ViewLikeInterfaces.h. I think we already do this with some other parsers/printers somewhere else in the code base. I'd only put things on the interface that are supposed to generalize well across all of the use cases, parsers/printers generally don't. |
mlir/include/mlir/Interfaces/ViewLikeInterface.td | ||
---|---|---|
35 | Thanks! Parser and printer coming as followups. |
SubViewOp/SubTensorOp don't make sense to mention here.