The only change done to the Makefile to get a somewhat faster binary as
discussed in #2291 is to add -msse4 to the compile options of the bmi2 build.
Since all processors supporting bmi2 also support sse4 this can be done easily.
It is a useful step to avoid sending around custom and poorly tested builds.
The speedup isn't enough to pass [0,4] but it is roughly 1.15Elo and a LOS of 90%:
LLR: -2.95 (-2.94,2.94) [0.00,4.00]
Total: 93009 W: 20519 L: 20316 D: 52174
Also rewrite the documentation for the user when using `make --help`, so that
the order of architectures for x86-64 has the more performant build one on top.
Closes https://github.com/official-stockfish/Stockfish/pull/2300
No functional change
ifeq ($(pext),yes)
CXXFLAGS += -DUSE_PEXT
ifeq ($(comp),$(filter $(comp),gcc clang mingw))
ifeq ($(pext),yes)
CXXFLAGS += -DUSE_PEXT
ifeq ($(comp),$(filter $(comp),gcc clang mingw))
+ CXXFLAGS += -msse4 -mbmi2
@echo ""
@echo "Supported archs:"
@echo ""
@echo ""
@echo "Supported archs:"
@echo ""
- @echo "x86-64 > x86 64-bit"
- @echo "x86-64-modern > x86 64-bit with popcnt support"
- @echo "x86-64-bmi2 > x86 64-bit with pext support"
+ @echo "x86-64-bmi2 > x86 64-bit with pext support (also enables SSE4)"
+ @echo "x86-64-modern > x86 64-bit with popcnt support (also enables SSE3)"
+ @echo "x86-64 > x86 64-bit generic"
@echo "x86-32 > x86 32-bit with SSE support"
@echo "x86-32-old > x86 32-bit fall back for old hardware"
@echo "ppc-64 > PPC 64-bit"
@echo "x86-32 > x86 32-bit with SSE support"
@echo "x86-32-old > x86 32-bit fall back for old hardware"
@echo "ppc-64 > PPC 64-bit"