https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77558
Tom de Vries <vries at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |christophe.lyon at st dot com --- Comment #1 from Tom de Vries <vries at gcc dot gnu.org> --- This patch seems to fix the problem: ... diff --git a/gcc/builtins.c b/gcc/builtins.c index e779c71..93a5f3b 100644 --- a/gcc/builtins.c +++ b/gcc/builtins.c @@ -4089,10 +4089,7 @@ std_canonical_va_list_type (tree type) wtype = va_list_type_node; htype = type; - /* Treat structure va_list types. */ - if (TREE_CODE (wtype) == RECORD_TYPE && POINTER_TYPE_P (htype)) - htype = TREE_TYPE (htype); - else if (TREE_CODE (wtype) == ARRAY_TYPE) + if (TREE_CODE (wtype) == ARRAY_TYPE) { /* If va_list is an array type, the argument may have decayed to a pointer type, e.g. by being passed to another function. ... Should get some testing on aarch64.