Build with optimisation flags (and optionally AVX2)

Task Info (Flyspray)
Opened By Valérian Sibille (Dakeryas)
Task ID 74023
Type Feature Request
Project Community Packages
Category Packages
Version None
OS All
Opened 2022-03-04 00:09:04 UTC
Status Assigned
Assignee George Rawlinson (rawlinsong)

Details

Description: The current compression is four times slower than the AVX2 build on my machine (i7-7700HQ). The original author added AVX2 instructions in version 6.50 already, so I guess it would make sense to at least add -march=native in the build flags, such that AVX2 would be enable on any machine that support is. Even just including the O2 flag (which is not included in the author's Makefile, although it uses CXXFLAGS correctly if set) shrinks the compression time by a factor of three.

Steps to reproduce: Compare the WAV to APE conversion runtime with a manual build using export CXXFLAGS="${CXXFLAGS} -O3 -march=native" and GCC 11, with the runtime using the executable from package.