https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109510
--- Comment #9 from Eric Botcazou <ebotcazou at gcc dot gnu.org> --- > How do you get at the alignment the type would have when the user didn't > specify it? That's what the call ABI is supposed to look at. > > /* 1 if the alignment for this type was requested by "aligned" attribute, > 0 if it is the default for this type. */ > #define TYPE_USER_ALIGN(NODE) (TYPE_CHECK (NODE)->base.u.bits.user_align) > > so what's the "default" alignment? Note that the wording is ambiguous if the "aligned" attribute requests the same alignment as the default for the type, which is the case here: type Val is mod 2**Val_Bits with Alignment => Val_Bytes; The alignment clause is confirming in Ada parlance, which means that it does not change anything. We set TYPE_USER_ALIGN in this case, but I agree that we might as well not set it. Tentative patch to be attached.