]> git.ipfire.org Git - thirdparty/zlib-ng.git/commit
Enable AVX2 functions to be built with BMI2 instructions
authorAdam Stylinski <kungfujesus06@gmail.com>
Thu, 28 Nov 2024 00:00:52 +0000 (19:00 -0500)
committerHans Kristian Rosbach <hk-github@circlestorm.org>
Sat, 7 Dec 2024 21:32:29 +0000 (22:32 +0100)
commit7020cb3f74382c04b7d291a4d99108f088090b1a
tree95bf7f13ab230b6da3d03f6c1d42faaa29b6c94b
parent11bef87c1c795d8498393c1202bcba4b274a2539
Enable AVX2 functions to be built with BMI2 instructions

While these are technically different instructions, no such CPU exists
that has AVX2 that doesn't have BMI2. Enabling BMI2 allows us to
eliminate several flag stalls by having flagless versions of shifts, and
allows us to not clobber and move around GPRs so much in scalar code.
There's usually a sizeable benefit for enabling it. Since we're building
with BMI2 for AVX2 functions, let's also just make sure the CPU claims
to support it (just to cover our bases).
arch/x86/Makefile.in
cmake/detect-intrinsics.cmake
configure
functable.c