Re: [PATCH v2 05/11] x86: add CONFIG_X86_64_NATIVE option

From: irecca . kun
Date: Tue Dec 10 2024 - 16:09:05 EST


On 12/11/24 01:56, Arnd Bergmann wrote:
-ftree-vectorize is only enabled by default at -O3 level

You maybe missed it, but vectorization is enabled at -O2 level since GCC 12. https://www.phoronix.com/news/GCC-12-Auto-Vec-O2
Same goes for clang, it pretty much always had vectorized on -O2, iirc.

avx2 is already turned off because of -mno-avx,

Hmm, I'm not sure. But if we look at existing KBUILD_RUSTFLAGS below, it has both -avx and -avx2.