Go to:
Gentoo Home
Documentation
Forums
Lists
Bugs
Planet
Store
Wiki
Get Gentoo!
Gentoo's Bugzilla – Attachment 205198 Details for
Bug 270120
[4.4/bad-code] -ftree-vectorize causes segfaults on x86 due to stack misalignment
Home
|
New
–
[Ex]
|
Browse
|
Search
|
Privacy Policy
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
sse & 32bit -> -mstackrealign
sse-stackrealign-1.patch (text/plain), 2.57 KB, created by
Denis Kaganovich
on 2009-09-25 11:26:06 UTC
(
hide
)
Description:
sse & 32bit -> -mstackrealign
Filename:
MIME Type:
Creator:
Denis Kaganovich
Created:
2009-09-25 11:26:06 UTC
Size:
2.57 KB
patch
obsolete
>diff -pruN a/gcc/config/i386/i386.h b/gcc/config/i386/i386.h >--- a/gcc/config/i386/i386.h 2009-07-11 22:06:26.000000000 +0300 >+++ b/gcc/config/i386/i386.h 2009-09-25 13:33:17.000000000 +0300 >@@ -682,7 +682,9 @@ enum target_cpu_default > need a 16-byte aligned stack, as required by SSE instructions. If > STACK_REALIGN_DEFAULT is 1 and PREFERRED_STACK_BOUNDARY_DEFAULT is > 128, stacks for all functions may be realigned. */ >-#define STACK_REALIGN_DEFAULT 0 >+/* FIXME: I have no installed 3DNOW cpu to test */ >+#define STACK_REALIGN_DEFAULT \ >+ (((TARGET_SSE || TARGET_3DNOW) && !TARGET_64BIT) ? 1 : 0) > > /* Boundary (in *bits*) on which the incoming stack is aligned. */ > #define INCOMING_STACK_BOUNDARY ix86_incoming_stack_boundary >diff -pruN a/gcc/config/i386/t-i386 b/gcc/config/i386/t-i386 >--- a/gcc/config/i386/t-i386 2008-07-23 13:28:06.000000000 +0300 >+++ b/gcc/config/i386/t-i386 2009-09-25 13:35:11.000000000 +0300 >@@ -11,3 +11,9 @@ i386-c.o: $(srcdir)/config/i386/i386-c.c > $(TM_H) $(RTL_H) $(TREE_H) $(TM_P_H) $(FLAGS_H) $(C_COMMON_H) $(GGC_H) \ > $(TARGET_H) $(TARGET_DEF_H) $(CPPLIB_H) $(C_PRAGMA_H) > $(CC) -c $(ALL_CFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) $(srcdir)/config/i386/i386-c.c >+ >+TARGET_LIBGCC2_CFLAGS += -mno-stackrealign >+ >+# try if segfault to disable sse in gcc libs >+#TARGET_LIBGCC2_CFLAGS += -mno-sse -mno-3dnow >+ >diff -pruN a/gcc/doc/g++.1 b/gcc/doc/g++.1 >--- a/gcc/doc/g++.1 2009-07-22 11:23:37.000000000 +0300 >+++ b/gcc/doc/g++.1 2009-09-24 22:52:19.000000000 +0300 >@@ -10346,6 +10346,7 @@ runtime stack if necessary. This suppor > a 4\-byte aligned stack with modern codes that keep a 16\-byte stack for > \&\s-1SSE\s0 compatibility. See also the attribute \f(CW\*(C`force_align_arg_pointer\*(C'\fR, > applicable to individual functions. >+It is enabled by default at SSE on 32bit. > .IP "\fB\-mpreferred\-stack\-boundary=\fR\fInum\fR" 4 > .IX Item "-mpreferred-stack-boundary=num" > Attempt to keep the stack boundary aligned to a 2 raised to \fInum\fR >diff -pruN a/gcc/doc/gcc.1 b/gcc/doc/gcc.1 >--- a/gcc/doc/gcc.1 2009-07-22 10:53:09.000000000 +0300 >+++ b/gcc/doc/gcc.1 2009-09-24 22:52:19.000000000 +0300 >@@ -10346,6 +10346,7 @@ runtime stack if necessary. This suppor > a 4\-byte aligned stack with modern codes that keep a 16\-byte stack for > \&\s-1SSE\s0 compatibility. See also the attribute \f(CW\*(C`force_align_arg_pointer\*(C'\fR, > applicable to individual functions. >+It is enabled by default at SSE on 32bit. > .IP "\fB\-mpreferred\-stack\-boundary=\fR\fInum\fR" 4 > .IX Item "-mpreferred-stack-boundary=num" > Attempt to keep the stack boundary aligned to a 2 raised to \fInum\fR
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 270120
:
201741
| 205198