bug-hurd
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[PATCH,boehm-gc] Use mmap instead of brk on kfreebsd & hurd too


From: Samuel Thibault
Subject: [PATCH,boehm-gc] Use mmap instead of brk on kfreebsd & hurd too
Date: Sun, 31 Aug 2014 17:20:04 +0200
User-agent: Mutt/1.5.21+34 (58baf7c9f32f) (2010-12-30)

Hello,

Please use mmap instead of brk on kfreebsd and hurd too.
Also, using anonymous memory is faster on the Hurd.

Thanks,
Samuel

2014-08-31  Samuel Thibault  <samuel.thibault@ens-lyon.org>

        * configure.host: Set gc_use_mmap on *-kfreebsd-gnu* and *-gnu*.
        * include/private/gcconfig.h [HURD && USE_MMAP]: Define USE_MMAP_ANON.

Index: boehm-gc/configure.host
===================================================================
--- boehm-gc/configure.host     (révision 214763)
+++ boehm-gc/configure.host     (copie de travail)
@@ -41,7 +41,7 @@
 fi
 
 case "${host}" in
-  *-linux*)
+  *-linux*|*-kfreebsd-gnu*|*-gnu*)
     gc_use_mmap=yes
     ;;
 esac
Index: boehm-gc/include/private/gcconfig.h
===================================================================
--- boehm-gc/include/private/gcconfig.h (révision 214763)
+++ boehm-gc/include/private/gcconfig.h (copie de travail)
@@ -2132,7 +2132,7 @@
 #   endif
 # endif
 
-#if defined(LINUX) && defined(USE_MMAP)
+#if (defined(LINUX) || defined(HURD)) && defined(USE_MMAP)
     /* The kernel may do a somewhat better job merging mappings etc.   */
     /* with anonymous mappings.                                                
*/
 #   define USE_MMAP_ANON



reply via email to

[Prev in Thread] Current Thread [Next in Thread]