https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66325
--- Comment #3 from Jan Hubicka <hubicka at gcc dot gnu.org> --- OK, I found where the packed flag is originating from. It is start_enum that set TYPE_PACKED for flag_short_enums. I suppose it needs to iterate through all variants.