https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95748

            Bug ID: 95748
           Summary: Long long function parameter should be aligned to 32
                    bit on x86.
           Product: gcc
           Version: 11.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: target
          Assignee: unassigned at gcc dot gnu.org
          Reporter: skpgkp2 at gmail dot com
                CC: hjl.tools at gmail dot com
  Target Milestone: ---

Long long function parameter should be aligned to 32 bit on x86 target.

$ cat paramtest.c
void foo(int x, long long p)
{
        if (__alignof__(p) != 4 )
          __builtin_abort();
}
int bar()
{
        foo(4,5);
        return 0;
}
int main()
{
        return(bar());
}

$ gcc -m32 paramtest.c
$ ./a.out
Aborted (core dumped)

Reply via email to