As seen here https://lnt.opensuse.org/db_default/v4/SPEC/graph?plot.0=800.437.0 there was a 5% exec time slowdown of the 507.cactuBSSN_r SPEC 2017 benchmark between commits r15-7920-g62a6a53766ba46 r15-7936-gc6b277f1dc6d11 when run with -O2 -march=generic -flto on an Intel Ice Lake (3rd generation Xeon) machine.
From my bisect, it might caused by r15-7932 on single copy for Ice Lake. Guilty Commit: e355fe414aa3aaf215c7dd9dd789ce217a1b458c Author: Vladimir N. Makarov Date: 2025-03-11 04:27:51 Tuesday Diff: -2.45499181669395% Message: [PR114991][IRA]: Improve reg equiv invariant calculation In PR test case IRA preferred to allocate hard reg to a pseudo instead of its equivalence. This resulted in allocating caller-saved hard reg and generating save/restore insns in the function prologue/epilogue. The equivalence is an invariant (stack pointer plus offset) and the pseudo is used mostly as memory address. This happened as there was no simplification of insn after the invariant substitution. The patch adds the necessary code.
Thank you for reporting this. I am working on analogous PR119285. I think the fix will be ready on this week.
(In reply to Vladimir Makarov from comment #2) > Thank you for reporting this. I am working on analogous PR119285. I think > the fix will be ready on this week. Unfortunately, the patch for PR119285 did not solve cactuBSSN slow down. I'll be working on this issue and try to fix it as soon as possible, definitely on this week.
The master branch has been updated by Vladimir Makarov <vmakarov@gcc.gnu.org>: https://gcc.gnu.org/g:6c443e128802bd93158a3db7c4edf5fc1fc76c8d commit r15-8449-g6c443e128802bd93158a3db7c4edf5fc1fc76c8d Author: Vladimir N. Makarov <vmakarov@redhat.com> Date: Wed Mar 19 16:06:41 2025 -0400 [PR119270][IRA]: Ignore equiv init insns for cost calculation for invariants only My previous patch for PR114991 contains code ignoring equiv init insns for increasing cost of usage the equivalence. Although common sense says it is right thing to do, this results in more aggressive usage of memory equivalence and significant performance degradation of SPEC2017 cactuBSSM. Given patch restores previous cost calculation for all equivalences except for invariant ones. gcc/ChangeLog: PR target/119270 * ira-costs.cc (calculate_equiv_gains): Ignore equiv init insns only for invariants.
From my run, it should have fixed the regression. Thx!
Looks fixed even on our benchmarking machine :). Closing.