[Mlir-commits] [mlir] [MLIR] Add fusability query to TilingInterface (PR #166502)
Quinn Dawkins
llvmlistbot at llvm.org
Thu Nov 6 05:34:12 PST 2025
================
@@ -359,6 +359,52 @@ struct LinalgOpTilingInterface
/// Inline the op payload and store the result.
return inlinePayload(builder, linalgOp, ivs, indexedValues);
}
+
+ bool isOpFusableWithConsumerSlice(Operation *op, unsigned resultNumber,
+ ArrayRef<OpFoldResult> offsets,
+ ArrayRef<OpFoldResult> sizes) const {
+ return !cast<LinalgOp>(op).getShapesToLoopsMap();
----------------
qedawkins wrote:
The op's iteration space isn't invertible if the ShapesToLoopsMap doesn't exist (e.g. in the case of exotic indexing maps that include mods and divs). In the case of linalg ops support for such maps is unimplemented (we could emit loops directly) but we still need to reflect the unimplemented case here.
https://github.com/llvm/llvm-project/pull/166502
More information about the Mlir-commits
mailing list