https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106518
Jan Hubicka <hubicka at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |hubicka at gcc dot gnu.org --- Comment #2 from Jan Hubicka <hubicka at gcc dot gnu.org> --- We have xchg patterns in i386.md and corresponding peephole. I used to play with this long time ago and it was not giving any of performance benefits becuase xchg at that time was not well optimized in CPUs. With regstack the main problem is that RTL after reg-stack is inconsistent since we have no way to explicitly express push/pop operations that renumber the registers. Some years ago I made patch for that https://gcc.gnu.org/pipermail/gcc-patches/1999-November/021921.html Even if you make representation correct register allocation for stack based CPU is quite different from normal registr allocation. These days I would more like to see x87 to silently die.