]> gcc.gnu.org Git - gcc.git/commitdiff
re PR libgcj/19823 (java fails with non-executable memory)
authorBryce McKinlay <mckinlay@redhat.com>
Wed, 16 Feb 2005 04:10:42 +0000 (04:10 +0000)
committerBryce McKinlay <bryce@gcc.gnu.org>
Wed, 16 Feb 2005 04:10:42 +0000 (04:10 +0000)
2005-02-15  Bryce McKinlay  <mckinlay@redhat.com>

PR libgcj/19823
* configure.host: Set gc_use_mmap on *-linux*.
* configure.ac: Define USE_MMAP if gc_use_mmap is set.
* include/private/gc_priv.h: Include gc_config.h.
* configure, include/gc_config.h.in: Rebuilt.

From-SVN: r95094

boehm-gc/ChangeLog
boehm-gc/configure
boehm-gc/configure.ac
boehm-gc/configure.host
boehm-gc/include/gc_config.h.in
boehm-gc/include/private/gc_priv.h

index b9c7c46ae0599856d27094092c54ab7486b2c76c..2194ad5863fdfc9989e7f6ce5fbed8f5b8e99bbd 100644 (file)
@@ -1,3 +1,11 @@
+2005-02-15  Bryce McKinlay  <mckinlay@redhat.com>
+
+       PR libgcj/19823
+       * configure.host: Set gc_use_mmap on *-linux*.
+       * configure.ac: Define USE_MMAP if gc_use_mmap is set.
+       * include/private/gc_priv.h: Include gc_config.h.
+       * configure, include/gc_config.h.in: Rebuilt.
+
 2005-02-07  Hans Boehm  <Hans.Boehm@hp.com>
 
        * allchblk.c (GC_allochblk_nth): Dont overlook available space if
index 36243d4c58b09fa2019d746d686d3976c33a6b54..b205d328c03ed4549c41707f3165b6e0bccb762a 100755 (executable)
@@ -6558,6 +6558,14 @@ _ACEOF
   fi
 fi;
 
+if test "${gc_use_mmap}" = "yes"; then
+
+cat >>confdefs.h <<\_ACEOF
+#define USE_MMAP 1
+_ACEOF
+
+fi
+
 if test -n "$with_cross_host" &&
    test x"$with_cross_host" != x"no"; then
   toolexecdir='$(exec_prefix)/$(target_noncanonical)'
index 208a916087219c02add8a0cfb32275363285d0d9..dfb0e17e2611e01f556e45792bca190f742118b5 100644 (file)
@@ -446,6 +446,10 @@ AC_ARG_ENABLE(gc-debug,
     esac 
   fi])
 
+if test "${gc_use_mmap}" = "yes"; then
+  AC_DEFINE(USE_MMAP, 1, [use MMAP instead of sbrk to get new memory])
+fi
+
 if test -n "$with_cross_host" &&
    test x"$with_cross_host" != x"no"; then
   toolexecdir='$(exec_prefix)/$(target_noncanonical)'
index a98a0a7cb30cc48a0035ac6b2fa4954b6542cf31..97f4dacb6deef195b42e58e165ccac5d447a9d28 100644 (file)
 
 # It sets the following shell variables:
 #   gc_cflags  Special CFLAGS to use when building
+#   gc_use_mmap  Set to "yes" on platforms where mmap should be used instead
+#               of sbrk. This will define USE_MMAP.
 
 gc_cflags=""
+gc_use_mmap=
 
 # We should set -fexceptions if we are using gcc and might be used
 # inside something like gcj.  This is the zeroth approximation:
@@ -37,6 +40,12 @@ else
     esac
 fi
 
+case "${host}" in
+  *-linux*)
+    gc_use_mmap=yes
+    ;;
+esac
+
 case "${target_optspace}:${host}" in
   yes:*)
     gc_cflags="${gc_cflags} -Os"
index 60ffb9741b60fe816668f9488b07425d106938bb..92f1b2cf4607c30bb29d0da5914e5e55b220e52d 100644 (file)
 /* define GC_local_malloc() & GC_local_malloc_atomic() */
 #undef THREAD_LOCAL_ALLOC
 
+/* use MMAP instead of sbrk to get new memory */
+#undef USE_MMAP
+
 /* POSIX version of C Source */
 #undef _POSIX_C_SOURCE
 
index e5bd52b62b77627764da55090b979d1049ec75eb..c336ce5c433dbb2c7897a0ce372b0a0dc171144b 100644 (file)
 # ifndef GC_PRIVATE_H
 # define GC_PRIVATE_H
 
+/* Autoconf definitions. */
+/* FIXME: This should really be included directly from each .c file. */
+#include <gc_config.h>
+
 #if defined(mips) && defined(SYSTYPE_BSD) && defined(sony_news)
     /* sony RISC NEWS, NEWSOS 4 */
 #   define BSD_TIME
This page took 0.076722 seconds and 5 git commands to generate.