https://gcc.gnu.org/bugzilla/show_bug.cgi?id=120839
--- Comment #10 from Richard Biener <rguenth at gcc dot gnu.org> ---
In fact the AMD64 ABI says "If the class is MEMORY ,pass trhe argument on the
stack at an address respecting the arguments alignemnt (which might be more
than its natural alignment). So
diff --git a/gcc/config/i386/i386.cc b/gcc/config/i386/i386.cc
index acedc73b825..b43d50b6bc3 100644
--- a/gcc/config/i386/i386.cc
+++ b/gcc/config/i386/i386.cc
@@ -3803,9 +3803,6 @@ ix86_function_arg_boundary (machine_mode mode, const_tree
type)
unsigned int align;
if (type)
{
- /* Since the main variant type is used for call, we convert it to
- the main variant type. */
- type = TYPE_MAIN_VARIANT (type);
align = TYPE_ALIGN (type);
if (TYPE_EMPTY_P (type))
return PARM_BOUNDARY;
looks correct to me and we then diagnose:
> ./cc1 -quiet t.c -O
t.c: In function āeā:
t.c:5:6: note: the ABI for passing parameters with 32-byte alignment has
changed in GCC 4.6
5 | void e(c f) { d = f.a; }
| ^
what am I missing?