Bug 925169 - part 1 - don't use MOZ_MEMORY_SIZEOF_PTR_2POW in jemalloc.c; r=glandium
authorNathan Froyd <froydnj@mozilla.com>
Wed, 09 Oct 2013 19:04:43 -0400
changeset 164263 35816c397a141c626fad6f66e834dafd052a35f2
parent 164262 06b787f4b5c4ebc136a8d22e2114b201ff82072a
child 164264 6ae66f8f377bd378706c911adda439e9b6ad679e
push id3066
push userakeybl@mozilla.com
push dateMon, 09 Dec 2013 19:58:46 +0000
treeherdermozilla-beta@a31a0dce83aa [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersglandium
bugs925169
milestone27.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 925169 - part 1 - don't use MOZ_MEMORY_SIZEOF_PTR_2POW in jemalloc.c; r=glandium
memory/mozjemalloc/jemalloc.c
--- a/memory/mozjemalloc/jemalloc.c
+++ b/memory/mozjemalloc/jemalloc.c
@@ -294,17 +294,17 @@ getenv(const char *name)
 
 	return (NULL);
 }
 
 typedef unsigned char uint8_t;
 typedef unsigned uint32_t;
 typedef unsigned long long uint64_t;
 typedef unsigned long long uintmax_t;
-#if defined(MOZ_MEMORY_SIZEOF_PTR_2POW) && (MOZ_MEMORY_SIZEOF_PTR_2POW == 3)
+#if defined(_WIN64)
 typedef long long ssize_t;
 #else
 typedef long ssize_t;
 #endif
 
 #define	MALLOC_DECOMMIT
 #endif
 
@@ -464,18 +464,18 @@ static const bool isthreaded = true;
 #  define inline
 #endif
 
 /* Size of stack-allocated buffer passed to strerror_r(). */
 #define	STRERROR_BUF		64
 
 /* Minimum alignment of non-tiny allocations is 2^QUANTUM_2POW_MIN bytes. */
 #  define QUANTUM_2POW_MIN      4
-#ifdef MOZ_MEMORY_SIZEOF_PTR_2POW
-#  define SIZEOF_PTR_2POW		MOZ_MEMORY_SIZEOF_PTR_2POW
+#if defined(_WIN64) || defined(__LP64__)
+#  define SIZEOF_PTR_2POW       3
 #else
 #  define SIZEOF_PTR_2POW       2
 #endif
 #define PIC
 #ifndef MOZ_MEMORY_DARWIN
 static const bool isthreaded = true;
 #else
 #  define NO_TLS