[Mlir-commits] [mlir] [MLIR] Make 1-D memref flattening a prerequisite for vector narrow type emulation (PR #157771)
Andrzej WarzyĆski
llvmlistbot at llvm.org
Fri Sep 12 08:36:18 PDT 2025
================
@@ -817,7 +818,13 @@ struct ConvertVectorStore final : OpConversionPattern<vector::StoreOp> {
// ConvertVectorMaskedStore
//===----------------------------------------------------------------------===//
-// TODO: Document-me
+/// Converts `vector.maskedstore` operations on narrow element types to work
+/// with wider, byte-aligned container types by adjusting the mask and using
+/// bitcasting.
+///
+/// Example: Storing `vector<6xi4>` is emulated by bitcasting to `vector<3xi8>`
+/// and storing with an adjusted mask, since each `i8` container element holds
+/// two `i4` values.
----------------
banach-space wrote:
IMHO, this will flow a bit better.
```suggestion
/// Example: Storing `vector<6xi4>` is emulated by bitcasting to `vector<3xi8>` (each `i8` container element holds
/// two `i4` values) and storing with an adjusted mask .
```
https://github.com/llvm/llvm-project/pull/157771
More information about the Mlir-commits
mailing list