diff options
| author | Richard Henderson <richard.henderson@linaro.org> | 2021-07-23 10:33:44 -1000 |
|---|---|---|
| committer | Peter Maydell <peter.maydell@linaro.org> | 2021-07-27 10:57:40 +0100 |
| commit | b3d52804c591b478ec0620253c2bd71e4ff87bb9 (patch) | |
| tree | 287bbaa7f2a03b6e837dae465cee9d75b1118dd7 /target/arm/cpu.h | |
| parent | ce440581c1446e56d911d83c9c3b760ae4f98b3e (diff) | |
| download | focaccia-qemu-b3d52804c591b478ec0620253c2bd71e4ff87bb9.tar.gz focaccia-qemu-b3d52804c591b478ec0620253c2bd71e4ff87bb9.zip | |
target/arm: Add sve-default-vector-length cpu property
Mirror the behavour of /proc/sys/abi/sve_default_vector_length under the real linux kernel. We have no way of passing along a real default across exec like the kernel can, but this is a decent way of adjusting the startup vector length of a process. Resolves: https://gitlab.com/qemu-project/qemu/-/issues/482 Signed-off-by: Richard Henderson <richard.henderson@linaro.org> Reviewed-by: Peter Maydell <peter.maydell@linaro.org> Message-id: 20210723203344.968563-4-richard.henderson@linaro.org [PMM: tweaked docs formatting, document -1 special-case, added fixup patch from RTH mentioning QEMU's maximum veclen.] Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'target/arm/cpu.h')
| -rw-r--r-- | target/arm/cpu.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/target/arm/cpu.h b/target/arm/cpu.h index be9a4dceae..9f0a5f84d5 100644 --- a/target/arm/cpu.h +++ b/target/arm/cpu.h @@ -1006,6 +1006,11 @@ struct ARMCPU { /* Used to set the maximum vector length the cpu will support. */ uint32_t sve_max_vq; +#ifdef CONFIG_USER_ONLY + /* Used to set the default vector length at process start. */ + uint32_t sve_default_vq; +#endif + /* * In sve_vq_map each set bit is a supported vector length of * (bit-number + 1) * 16 bytes, i.e. each bit number + 1 is the vector |