This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug rtl-optimization/40838] gcc shouldn't assume that the stack is aligned
- From: "mikulas at artax dot karlin dot mff dot cuni dot cz" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 23 Jul 2009 13:49:10 -0000
- Subject: [Bug rtl-optimization/40838] gcc shouldn't assume that the stack is aligned
- References: <bug-40838-1600@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #7 from mikulas at artax dot karlin dot mff dot cuni dot cz 2009-07-23 13:49 -------
See bug #27537, quoting "GNU/Linux follows the SYSV x86 ABI which is
documented, maybe you cannot find it but it does exist. The SYSV x86 ABI says
the stack is aligned 4 byte aligned."
That bug seems to reappear.
As Agner noted, 16-byte stack alignment requirement also break compatibility
with Intel CC. I found even some part of current glibc that violates this
16-byte alignment (calling push %eax; call exit from the assembler without
aligning the stack size).
Another point: if gcc realigns the stack, why then use movdqu to store the
values on the stack? That is suboptimal.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40838