Hi Robin:
The document is written down in psABI:
https://github.com/riscv-non-isa/riscv-elf-psabi-doc/pull/418/files
Related wording for that is:
A fixed-length vector argument is passed in one vector argument register if the
size of the vector is less than or equal to ABI_VLEN bit.
A fixed-length vector argument is passed in two vector argument registers,
similar to vector data arguments with LMUL=2 and following the same register
constraints, if the size of the vector is greater than ABI_VLEN bits and less
than or equal to 2×ABI_VLEN bits.
...
and vice versa until 2xABI_VLEN
Also VLS calling convention also considers tuple type.
e.g.
struct int32x8x2_t {
int32x8_t v1;
int32x8_t v2;
}
It will become LMULx2 x2 (RVVM2x2SI) when ABI_VLEN=128
On Wed, Sep 10, 2025 at 3:18 PM Robin Dapp <[email protected]> wrote:
>
> Hi Kito,
>
> we discussed this in yesterday's patchwork sync. Would you mind sharing what
> the current LLVM implementation does and if this is written down/documented
> somewhere?
>
> In particular the chunk size we split large vectors. Like for a 1024b vector
> with the "128b ABI", does LLVM use LMUL8, i.e. always the largest possible
> LMUL, or is there another limit?
>
> --
> Regards
> Robin
>