Bug 1134123 - Disable (infinite) chunk recycling in jemalloc3. r=njn
authorMike Hommey <mh+mozilla@glandium.org>
Wed, 18 Feb 2015 17:04:47 +0900
changeset 230407 3bc7f92f4934f2ecfc4616d3babbed83d8909dbb
parent 230406 36a51f808aa59df4c5391c3791d02c628ba9129c
child 230408 a279774a1f3bf135b87c4de2eab534dc7e2edeac
push id28324
push usercbook@mozilla.com
push dateTue, 24 Feb 2015 11:56:37 +0000
treeherdermozilla-central@007c562fab9e [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersnjn
bugs1134123, 1107677
milestone39.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1134123 - Disable (infinite) chunk recycling in jemalloc3. r=njn Jemalloc 3 has, by default, a form of chunk recycling enabled, where it actually doesn't unmap any chunk it ever allocated. Considering Gecko has other uses of mmap, it can lead to premature address space exhaustion. Until we have actual (limited) chunk recycling in jemalloc3 from bug 1107677, just disable this feature.
configure.in
--- a/configure.in
+++ b/configure.in
@@ -9125,16 +9125,19 @@ if test -z "$MOZ_NATIVE_JEMALLOC" -a "$M
     ac_configure_args="$ac_configure_args $var='`eval echo \\${${var}}`'"
   done
   if test "$CROSS_COMPILE"; then
     ac_configure_args="$ac_configure_args je_cv_static_page_shift=12"
   fi
   # Force disable DSS support in jemalloc.
   ac_configure_args="$ac_configure_args ac_cv_func_sbrk=false"
 
+  # Make Linux builds munmap freed chunks instead of recycling them.
+  ac_configure_args="$ac_configure_args --enable-munmap"
+
   if ! test -e memory/jemalloc; then
     mkdir -p memory/jemalloc
   fi
 
   AC_OUTPUT_SUBDIRS(memory/jemalloc/src)
   ac_configure_args="$_SUBDIR_CONFIG_ARGS"
 fi