https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65690
--- Comment #5 from Jan Hubicka <hubicka at gcc dot gnu.org> --- Jason, I think I need a help on this one. I am not able to get canonical types right in all cases. Also I added the following sanity check that seems to trigger in the testuiste Index: ../../gcc/stor-layout.c =================================================================== --- ../../gcc/stor-layout.c (revision 221909) +++ ../../gcc/stor-layout.c (working copy) @@ -1831,6 +1831,8 @@ finalize_type_size (tree type) { TYPE_SIZE (variant) = size; TYPE_SIZE_UNIT (variant) = size_unit; + if (TYPE_USER_ALIGN (variant)) + gcc_assert (user_align && TYPE_ALIGN (variant) == align); TYPE_ALIGN (variant) = align; TYPE_PRECISION (variant) = precision; TYPE_USER_ALIGN (variant) = user_align;