https://gcc.gnu.org/bugzilla/show_bug.cgi?id=115018
--- Comment #1 from Andrew Pinski <pinskia at gcc dot gnu.org> --- First I can't reproduce it with the official releases GCC 13.2.0. Second with the trunk, I am not sure if this is a bug or not. With the trunk with `-O3 -Wall -Wextra -fno-strict-aliasing -fwrapv -fno-aggressive-loop-optimizations -march=armv8.2-a+sve -msve-vector-bits=256 ` Running under qemu like this: [apinski@xeond2 upstream-cross-aarch64]$ ./install-qemu/bin/qemu-aarch64 -cpu max,sve128=on,sve256=on a.out x[ 0]: 0 0 0 x[ 1]: 0 0 0 x[ 2]: 0 0 0 x[ 3]: 0 0 0 x[ 4]: 0 0 0 x[ 5]: 0 0 0 x[ 6]: 0 0 0 x[ 7]: 0 0 0 x[ 8]: 0 0 0 x[ 9]: 0 0 0 x[ 0]: 0 10 0 x[ 1]: 0 10 0 x[ 2]: 0 10 0 x[ 3]: 0 10 0 x[ 4]: 0 10 0 x[ 5]: 0 10 0 x[ 6]: 0 10 0 x[ 7]: 0 10 0 x[ 8]: 0 10 0 x[ 9]: 0 10 0 Works. But if I enable SVE512, it fails like you are describing: [apinski@xeond2 upstream-cross-aarch64]$ ./install-qemu/bin/qemu-aarch64 -cpu max,sve128=on,sve256=on,sve512=on a.out x[ 0]: 0 0 0 x[ 1]: 0 0 0 x[ 2]: 0 0 0 x[ 3]: 0 0 0 x[ 4]: 0 0 0 x[ 5]: 0 0 0 x[ 6]: 0 0 0 x[ 7]: 0 0 0 x[ 8]: 0 0 0 x[ 9]: 0 0 0 x[ 0]: 0 10 0 x[ 1]: 0 10 0 x[ 2]: 0 10 0 x[ 3]: 0 0 0 x[ 4]: 0 0 0 x[ 5]: 0 10 0 x[ 6]: 0 10 0 x[ 7]: 0 10 0 x[ 8]: 0 0 0 x[ 9]: 0 0 0