public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* [PATCH] fix PR pch/45979 regression on recent ARM/Linux kernels
@ 2010-10-26 20:14 Mikael Pettersson
  2010-11-19 11:45 ` [Ping][PATCH] " Mikael Pettersson
  0 siblings, 1 reply; 2+ messages in thread
From: Mikael Pettersson @ 2010-10-26 20:14 UTC (permalink / raw)
  To: gcc-patches

Post 2.6.35 ARM/Linux kernels now randomize mmap() by default,
which breaks precompiled headers.  See PR pch/45979.

Fixed by supplying an explicit hint for a likely free area
in the address space for precompiled headers to use, similar
to what has already been done for many other Linux archs.
Based on observation from several largish processes on an
arm-linux-gnueabi machine, 0xa0000000 seems to be a good
choice: it's just under the stack and at the end of a large
area populated by shared libraries.

Tested with gcc-4.6/4.5/4.4 on arm-linux-gnueabi running
2.6.36-rcN kernels.  Fixed all pch testsuite failures, with
no new regressions.

Ok for trunk/4.5/4.4?  (I don't havn svn write access.)

gcc/

2010-10-26  Mikael Pettersson  <mikpe@it.uu.se>

	PR pch/45979
	* config/host-linux.c (TRY_EMPTY_VM_SPACE): Define for __ARM_EABI__.

--- gcc-4.6-20101009/gcc/config/host-linux.c.~1~	2009-02-20 16:20:38.000000000 +0100
+++ gcc-4.6-20101009/gcc/config/host-linux.c	2010-10-13 15:24:28.000000000 +0200
@@ -86,6 +86,8 @@
 # define TRY_EMPTY_VM_SPACE	0x60000000
 #elif defined(__mc68000__)
 # define TRY_EMPTY_VM_SPACE	0x40000000
+#elif defined(__ARM_EABI__)
+# define TRY_EMPTY_VM_SPACE	0xa0000000
 #else
 # define TRY_EMPTY_VM_SPACE	0
 #endif

^ permalink raw reply	[flat|nested] 2+ messages in thread

* [Ping][PATCH] fix PR pch/45979 regression on recent ARM/Linux kernels
  2010-10-26 20:14 [PATCH] fix PR pch/45979 regression on recent ARM/Linux kernels Mikael Pettersson
@ 2010-11-19 11:45 ` Mikael Pettersson
  0 siblings, 0 replies; 2+ messages in thread
From: Mikael Pettersson @ 2010-11-19 11:45 UTC (permalink / raw)
  To: gcc-patches

Ping for http://gcc.gnu.org/ml/gcc-patches/2010-10/msg02252.html

If it helps: I hereby place this patch in the public domain.

On Tue, 26 Oct 2010 20:45:52 +0200, Mikael Pettersson wrote:
 > Post 2.6.35 ARM/Linux kernels now randomize mmap() by default,
 > which breaks precompiled headers.  See PR pch/45979.
 > 
 > Fixed by supplying an explicit hint for a likely free area
 > in the address space for precompiled headers to use, similar
 > to what has already been done for many other Linux archs.
 > Based on observation from several largish processes on an
 > arm-linux-gnueabi machine, 0xa0000000 seems to be a good
 > choice: it's just under the stack and at the end of a large
 > area populated by shared libraries.
 > 
 > Tested with gcc-4.6/4.5/4.4 on arm-linux-gnueabi running
 > 2.6.36-rcN kernels.  Fixed all pch testsuite failures, with
 > no new regressions.
 > 
 > Ok for trunk/4.5/4.4?  (I don't havn svn write access.)
 > 
 > gcc/
 > 
 > 2010-10-26  Mikael Pettersson  <mikpe@it.uu.se>
 > 
 > 	PR pch/45979
 > 	* config/host-linux.c (TRY_EMPTY_VM_SPACE): Define for __ARM_EABI__.
 > 
 > --- gcc-4.6-20101009/gcc/config/host-linux.c.~1~	2009-02-20 16:20:38.000000000 +0100
 > +++ gcc-4.6-20101009/gcc/config/host-linux.c	2010-10-13 15:24:28.000000000 +0200
 > @@ -86,6 +86,8 @@
 >  # define TRY_EMPTY_VM_SPACE	0x60000000
 >  #elif defined(__mc68000__)
 >  # define TRY_EMPTY_VM_SPACE	0x40000000
 > +#elif defined(__ARM_EABI__)
 > +# define TRY_EMPTY_VM_SPACE	0xa0000000
 >  #else
 >  # define TRY_EMPTY_VM_SPACE	0
 >  #endif

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2010-11-19  9:15 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-10-26 20:14 [PATCH] fix PR pch/45979 regression on recent ARM/Linux kernels Mikael Pettersson
2010-11-19 11:45 ` [Ping][PATCH] " Mikael Pettersson

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).