This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug target/10395] [x86] vector types are incorrectly aligned causing crash in multi-threaded apps or when using in main, plus other times
- From: "uros at kss-loka dot si" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 20 Dec 2004 13:16:13 -0000
- Subject: [Bug target/10395] [x86] vector types are incorrectly aligned causing crash in multi-threaded apps or when using in main, plus other times
- References: <20030413224600.10395.vgrebinski@yahoo.com>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From uros at kss-loka dot si 2004-12-20 13:16 -------
(In reply to comment #21)
> > The default pthread library in RedHat 8.0 does align stack properly, as I am
> > able to trigger the bug. Testcase shows:
>
> Uros, did you mean "does *not* align the stack properly"? If so, I would
> say yes, we should close the PR as WONTFIX, since we can't do anything
> about it.
Ouch... RH 8.0 does _NOT_ align stack properly.
However, on second thought, is it worth to add some kind of -mforce-stack-align
parameter to gcc? Or maybe an attribute to the function? This way, one could add
a stack alignment code, similar to main() stack alignment:
pushl %ebp
movl %esp, %ebp
subl $8, %esp
andl $-16, %esp <- this
subl $16, %esp
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=10395