[Mlir-commits] [mlir] [mlir][linalg] Upstream PackOp/UnPackOp's generateScalarImplementation. (PR #182838)
Abhishek Varma
llvmlistbot at llvm.org
Wed Feb 25 09:46:28 PST 2026
================
@@ -1292,6 +1470,62 @@ struct UnPackOpTiling
return tilingResult.value();
}
+ LogicalResult generateScalarImplementation(Operation *op, OpBuilder &builder,
+ Location loc,
+ ValueRange ivs) const {
+ auto unpackOp = cast<UnPackOp>(op);
+ assert(unpackOp.hasPureBufferSemantics() &&
+ "expected operation to have buffer semantics");
+ assert(ivs.size() == unpackOp.getDestRank() &&
+ "number of ivs must match the rank of the output tensor");
+ OpBuilder::InsertionGuard g(builder);
+
+ DenseMap<int64_t, OpFoldResult> dimAndTileMapping =
+ unpackOp.getDimAndTileMapping();
+ // untiled loops and tile loops induction variables.
+ SmallVector<Value> inputIvs;
+ // point loops induction variables.
----------------
Abhishek-Varma wrote:
Extreme nit to be consistent with other comments at least within the function:
```suggestion
// Untiled loops and tile loops induction variables.
SmallVector<Value> inputIvs;
// Point loops induction variables.
```
https://github.com/llvm/llvm-project/pull/182838
More information about the Mlir-commits
mailing list