This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug target/32893] zlib segfault in inflate_table() compiled w/ -O -msse2 ftree-vectorize
- From: "hjl dot tools at gmail dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 7 Feb 2008 22:15:34 -0000
- Subject: [Bug target/32893] zlib segfault in inflate_table() compiled w/ -O -msse2 ftree-vectorize
- References: <bug-32893-10406@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #21 from hjl dot tools at gmail dot com 2008-02-07 22:15 -------
The real problem is i386 gcc expects 16 byte stack boundary while the
psABI specifies 4 byte. When you link a callee, which expects incoming
stack at 16 byte boundary, with a caller, which only guarantees 4 byte
stack boundary, you will run into problem. The stack alignment branch can
automatically align the incoming stack. But we have to generate 16byte
stack boundary when calling a function by default since callees compiled by
older gcc expects 16 byte stack boundary. Since incoming stack is aligned
at 16byte by default, the stack alignment branch still assumes incoming
stack aligned at 16 byte by default. You can override it with -mstackrealign
or force_align_arg_pointer attribute, which will assume incoming stack is
aligned at 4 byte.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=32893