[Bug tree-optimization/85416] Massive performance regression when switching on "-march=native"
amonakov at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Tue Apr 17 13:31:00 GMT 2018
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=85416
--- Comment #13 from Alexander Monakov <amonakov at gcc dot gnu.org> ---
This is most likely a variant of
https://bugzilla.redhat.com/show_bug.cgi?id=1421121
so hitting this bug requires a specific CPU model.
It looks as if SSE-AVX transition penalties appear when switching between
pure-SSE sinf code and VEX-prefixed SSE code in the main program after the
ld.so runtime resolver affects AVX state tracking in the CPU.
I'm not sure if any patches have landed on Glibc side to avoid this, but in any
case this should be re-reported against Glibc if needed, GCC cannot improve the
situation.
An easy workaround would be to pass -Wl,-z,now when linking.
More information about the Gcc-bugs
mailing list