Bug 1091515 - Don't set 64KB page size on aarch64. r=glandium
authorMakoto Kato <m_kato@ga2.so-net.ne.jp>
Tue, 05 Apr 2016 18:54:42 +0900
changeset 291859 c111173a1b98ae219a1172cd7fb15dc8c629e2a2
parent 291858 26faa5d26ab77cec112d3d9a895d05cda09e08ef
child 291860 05ce1f2670ae52e928af76df72e78989935141e3
push idunknown
push userunknown
push dateunknown
reviewersglandium
bugs1091515
milestone48.0a1
Bug 1091515 - Don't set 64KB page size on aarch64. r=glandium Linux/aarch64 supports vairous page size configuration. (From https://www.kernel.org/doc/Documentation/arm64/memory.txt) - 4KB + 3 levels - 4KB + 4 levels - 64KB + 2 leves So we shouldn't set fixed 64KB page size on aarch64. MozReview-Commit-ID: 8IdwBMUW4me
memory/mozjemalloc/jemalloc.c
--- a/memory/mozjemalloc/jemalloc.c
+++ b/memory/mozjemalloc/jemalloc.c
@@ -1085,31 +1085,31 @@ static const bool config_recycle = true;
 static const bool config_recycle = false;
 #endif
 
 /*
  * When MALLOC_STATIC_SIZES is defined most of the parameters
  * controlling the malloc behavior are defined as compile-time constants
  * for best performance and cannot be altered at runtime.
  */
-#if !defined(__ia64__) && !defined(__sparc__) && !defined(__mips__)
+#if !defined(__ia64__) && !defined(__sparc__) && !defined(__mips__) && !defined(__aarch64__)
 #define MALLOC_STATIC_SIZES 1
 #endif
 
 #ifdef MALLOC_STATIC_SIZES
 
 /*
  * VM page size. It must divide the runtime CPU page size or the code
  * will abort.
  * Platform specific page size conditions copied from js/public/HeapAPI.h
  */
 #if (defined(SOLARIS) || defined(__FreeBSD__)) && \
     (defined(__sparc) || defined(__sparcv9) || defined(__ia64))
 #define pagesize_2pow			((size_t) 13)
-#elif defined(__powerpc64__) || defined(__aarch64__)
+#elif defined(__powerpc64__)
 #define pagesize_2pow			((size_t) 16)
 #else
 #define pagesize_2pow			((size_t) 12)
 #endif
 #define pagesize			((size_t) 1 << pagesize_2pow)
 #define pagesize_mask			(pagesize - 1)
 
 /* Various quantum-related settings. */