https://gcc.gnu.org/bugzilla/show_bug.cgi?id=84058
--- Comment #4 from Jan Hubicka <hubicka at gcc dot gnu.org> --- I noticed it while checking how well hot/cold partitioning works. Generally it seems to work well and brings measurable reduction of code cache misses on cc1plus runs. Still doing such stupid moves is a regression. I will implement simple fixup for this sillyness. I suppose fixup_partitions can look into simple BBs reached only from hot partition and not using any cold code and bring them back to hot. We could try to get fancier of course, but simple fixup may work well enough.
