[Bug target/27537] XMM alignment fault when compiling for i386 with -Os

2007-08-26 Thread zuxy dot meng at gmail dot com
--- Comment #17 from zuxy dot meng at gmail dot com 2007-08-26 07:58 --- *** Bug 28069 has been marked as a duplicate of this bug. *** -- zuxy dot meng at gmail dot com changed: What|Removed |Added

[Bug target/27537] XMM alignment fault when compiling for i386 with -Os

2007-07-22 Thread vda dot linux at googlemail dot com
--- Comment #15 from vda dot linux at googlemail dot com 2007-07-23 00:03 --- Disadvantages of enforcing 16-bytes stack alignment, continued: * Code to align the stack is generated when we call a function, even when this function isn't going to use SSE. Which is ~90% of all functions

[Bug target/27537] XMM alignment fault when compiling for i386 with -Os

2007-07-22 Thread vda dot linux at googlemail dot com
--- Comment #16 from vda dot linux at googlemail dot com 2007-07-23 00:48 --- You have it reversed here: 8. Stack alignment is already implemented in Gcc and existing code relies on it. No, stack alignment is _not_ in current de-facto i386 Linux ABI and there are tons of existing

[Bug target/27537] XMM alignment fault when compiling for i386 with -Os

2006-09-11 Thread hjl at gcc dot gnu dot org
--- Comment #13 from hjl at gcc dot gnu dot org 2006-09-11 21:34 --- Subject: Bug 27537 Author: hjl Date: Mon Sep 11 21:34:06 2006 New Revision: 116860 URL: http://gcc.gnu.org/viewcvs?root=gccview=revrev=116860 Log: gcc/ 2006-09-11 H.J. Lu [EMAIL PROTECTED] PR target/13685

[Bug target/27537] XMM alignment fault when compiling for i386 with -Os

2006-09-11 Thread hjl at gcc dot gnu dot org
--- Comment #14 from hjl at gcc dot gnu dot org 2006-09-12 02:54 --- Subject: Bug 27537 Author: hjl Date: Tue Sep 12 02:54:42 2006 New Revision: 116870 URL: http://gcc.gnu.org/viewcvs?root=gccview=revrev=116870 Log: gcc/ 2006-09-11 H.J. Lu [EMAIL PROTECTED] PR target/13685

[Bug target/27537] XMM alignment fault when compiling for i386 with -Os

2006-09-07 Thread hjl at lucon dot org
--- Comment #12 from hjl at lucon dot org 2006-09-08 00:45 --- *** This bug has been marked as a duplicate of 13685 *** -- hjl at lucon dot org changed: What|Removed |Added

[Bug target/27537] XMM alignment fault when compiling for i386 with -Os

2006-08-23 Thread agner at agner dot org
--- Comment #11 from agner at agner dot org 2006-08-23 08:04 --- This problem wouldn't have happened if the ABI had been better maintained. Somebody decides to change the calling convention without properly documenting the change, and somebody else makes another change that is

[Bug target/27537] XMM alignment fault when compiling for i386 with -Os

2006-08-21 Thread hjl at lucon dot org
--- Comment #10 from hjl at lucon dot org 2006-08-21 17:42 --- I have a mixed feeling toward this. On one hand, gcc does assume 16byte stack aligment. On the other hand, the original ia32 psABI only calls for 4 byte stack aliment. Requiring 16 byte aligment will make sure the outputs

[Bug target/27537] XMM alignment fault when compiling for i386 with -Os

2006-08-20 Thread mmitchel at gcc dot gnu dot org
--- Comment #9 from mmitchel at gcc dot gnu dot org 2006-08-20 22:29 --- It is definitely a bug to change the ABI with -Os. Since GCC relies on the stack being 16-byte aligned, -Os must in fact honor that requirement. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=27537

[Bug target/27537] XMM alignment fault when compiling for i386 with -Os

2006-08-03 Thread hjl at lucon dot org
--- Comment #7 from hjl at lucon dot org 2006-08-03 16:58 --- Apparently, it was done on purpose: http://gcc.gnu.org/ml/gcc-patches/2001-10/msg01161.html -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=27537

[Bug target/27537] XMM alignment fault when compiling for i386 with -Os

2006-08-03 Thread agner at agner dot org
--- Comment #8 from agner at agner dot org 2006-08-03 20:20 --- hjl wrote: Apparently, it was done on purpose Yes, the -Os non-alignment was obviously done on purpose. The problem is that other modules that may be called from the -Os module rely on the stack being aligned by 16. The

[Bug target/27537] XMM alignment fault when compiling for i386 with -Os

2006-06-08 Thread agner at agner dot org
--- Comment #6 from agner at agner dot org 2006-06-08 06:27 --- Comment #5 From hjl confirms my point: The error can occur in an optimized part of the program that uses XMM registers when some other, noncritical, part of the program is compiled with -Os We need a comment from the ABI

[Bug target/27537] XMM alignment fault when compiling for i386 with -Os

2006-06-07 Thread hjl at lucon dot org
--- Comment #5 from hjl at lucon dot org 2006-06-07 15:51 --- This testcase doesn't use -Os on SSE registers: [EMAIL PROTECTED] stack]$ cat m.c #include stdio.h extern char *e1 (void); int main () { printf (%s\n, e1 ()); return 0; } [EMAIL PROTECTED] stack]$ cat x.c #include

[Bug target/27537] XMM alignment fault when compiling for i386 with -Os

2006-05-11 Thread agner at agner dot org
--- Comment #4 from agner at agner dot org 2006-05-11 07:11 --- Thanks for confirming this bug. If Gcc relies on the stack being aligned then it has to be an official ABI requirement. It makes perfectly sense to compile the whole program, or some of it, with -Os and also use XMM. -Os

[Bug target/27537] XMM alignment fault when compiling for i386 with -Os. Needs ABI specification.

2006-05-10 Thread pinskia at gcc dot gnu dot org
--- Comment #1 from pinskia at gcc dot gnu dot org 2006-05-10 20:39 --- First so what darwin aligns the stack by default to 16bytes (that is demanded by their ABI since their ABI is newer than GNU/Linux's). GNU/Linux follows the SYSV x86 ABI which is documented, maybe you cannot find

[Bug target/27537] XMM alignment fault when compiling for i386 with -Os. Needs ABI specification.

2006-05-10 Thread pinskia at gcc dot gnu dot org
--- Comment #2 from pinskia at gcc dot gnu dot org 2006-05-10 20:44 --- The SYSV x86 ABI says the stack is aligned 4 byte aligned. Remember the SYSV x86 ABI was done before MMX or SSE was around or even thought about back in the 486 days (and maybe even before then). --

[Bug target/27537] XMM alignment fault when compiling for i386 with -Os

2006-05-10 Thread pinskia at gcc dot gnu dot org
--- Comment #3 from pinskia at gcc dot gnu dot org 2006-05-10 20:49 --- This is confirmed, this is an interaction between stack slots and -mpreferred-stack-boundary= which is what -Os sets. This is not a regression. Maybe the real question is why are you using -Os for code with SSE in