https://gcc.gnu.org/bugzilla/show_bug.cgi?id=110963
--- Comment #7 from Jan Hubicka <hubicka at gcc dot gnu.org> --- We don't consider main cold, but executed once: code out of loops is optimized for size, but anything in loops is optimized according to -O setting. I did not really think of users overwriting it by hot attribute, but looking into implementation it will work :)