https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78664
--- Comment #2 from Vladimir Makarov <vmakarov at gcc dot gnu.org> --- During register assignment subpass LRA processes hard regs from ira_class_hard_regs. Under the same conditions (e.g. costs), LRA chooses regs processed first. ira_class_hard_regs contains regs according REG_ALLOC_ORDER. LRA has code for balanced use of hard regs (controlled by hook register_usage_leveling_p). But now by default it is switched off. Probably the issue occurred when the code was switched on. To be sure I tried the test case and I was not able to reproduce the problem. So I think the problem has been solved.