[Mlir-commits] [mlir] [MLIR][Vector]Generalize DropUnitDimFromElementwiseOps (PR #92934)
Andrzej WarzyĆski
llvmlistbot at llvm.org
Mon Jun 3 09:58:16 PDT 2024
================
@@ -1607,7 +1607,27 @@ struct ChainedReduction final : OpRewritePattern<vector::ReductionOp> {
}
};
-/// For vectors with either leading or trailing unit dim, replaces:
+/// Drop unit dimension of the input VectorType. Scalable dimensions cannot be
+/// folded as we do not want to merge them through a shape_cast and create ill
+/// shaped scalable sizes.
----------------
banach-space wrote:
> Scalable dimensions cannot be folded as we do not want to merge them through a shape_cast and create ill shaped scalable sizes.
This is a bit more nuanced :)
> Scalable unit dimensions are not supported. Folding such dimensions would require "shifting" the scalable flag onto some other fixed-width dim (e.g. `vector<[1]x4xf32>` -> `vector<[4]xf32>`). This could be implemented in the future.
@MacDue Was there any other issue with unit scalable dims that I missed here?
https://github.com/llvm/llvm-project/pull/92934
More information about the Mlir-commits
mailing list