[Mlir-commits] [mlir] [NFC] Make AggregateOpInterface part of mlir:: instead of linalg:: (PR #70089)

Abhishek Varma llvmlistbot at llvm.org
Wed Oct 25 08:12:03 PDT 2023


Abhishek-Varma wrote:

> The change looks fine but what is your use case?
> 
> Also, we may want to also move the `DecomposeInterfaceOp` transform operation in the generic part.

Hi @dcaballe 

So, the use case occurs in IREE where we have operations from `LinalgExt` like `Attention`, `WinogradInputTransformOp` and `WinogradOutputTransformOp` which we decompose into finer set of operations.
The cleaner way to do that would be for them to adhere to `AggregateOpInterface`'s contract and invoke their decompositions via `decomposeOperation`.
But since `AggregateOpInterface` is tightly bound to `linalg` currently, including it straightaway is not possible - so we're trying to move this at a generic namespace for anyone to be able to implement their operation's decomposition using this interface and therefore also reduce the extra number of decomposition passes one way require.

Also regarding the `DecomposeInterfaceOp` - can we take it up in a subsequent revision? A quick search shows that `applyToOne` has far too many users and perhaps it'd be better if we address it in a separate PR.

CC: @MaheshRavishankar 

https://github.com/llvm/llvm-project/pull/70089


More information about the Mlir-commits mailing list