Module Name: src
Committed By: christos
Date: Mon Sep 23 21:08:37 UTC 2024
Modified Files:
src/external/bsd/jemalloc/include/jemalloc: jemalloc.h jemalloc_defs.h
src/external/bsd/jemalloc/include/jemalloc/internal:
jemalloc_internal_defs.h
Log Message:
byteorder and _LP64 changes
To generate a diff of this commit:
cvs rdiff -u -r1.7 -r1.8 \
src/external/bsd/jemalloc/include/jemalloc/jemalloc.h
cvs rdiff -u -r1.3 -r1.4 \
src/external/bsd/jemalloc/include/jemalloc/jemalloc_defs.h
cvs rdiff -u -r1.15 -r1.16 \
src/external/bsd/jemalloc/include/jemalloc/internal/jemalloc_internal_defs.h
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/external/bsd/jemalloc/include/jemalloc/jemalloc.h
diff -u src/external/bsd/jemalloc/include/jemalloc/jemalloc.h:1.7 src/external/bsd/jemalloc/include/jemalloc/jemalloc.h:1.8
--- src/external/bsd/jemalloc/include/jemalloc/jemalloc.h:1.7 Mon Sep 23 11:03:43 2024
+++ src/external/bsd/jemalloc/include/jemalloc/jemalloc.h Mon Sep 23 17:08:37 2024
@@ -57,7 +57,11 @@ extern "C" {
#endif
/* sizeof(void *) == 2^LG_SIZEOF_PTR. */
+#ifdef _LP64
#define LG_SIZEOF_PTR 3
+#else
+#define LG_SIZEOF_PTR 2
+#endif
/*
* Name mangling for public symbols is controlled by --with-mangling and
Index: src/external/bsd/jemalloc/include/jemalloc/jemalloc_defs.h
diff -u src/external/bsd/jemalloc/include/jemalloc/jemalloc_defs.h:1.3 src/external/bsd/jemalloc/include/jemalloc/jemalloc_defs.h:1.4
--- src/external/bsd/jemalloc/include/jemalloc/jemalloc_defs.h:1.3 Mon Sep 23 11:03:43 2024
+++ src/external/bsd/jemalloc/include/jemalloc/jemalloc_defs.h Mon Sep 23 17:08:37 2024
@@ -52,4 +52,8 @@
#endif
/* sizeof(void *) == 2^LG_SIZEOF_PTR. */
+#ifdef _LP64
#define LG_SIZEOF_PTR 3
+#else
+#define LG_SIZEOF_PTR 2
+#endif
Index: src/external/bsd/jemalloc/include/jemalloc/internal/jemalloc_internal_defs.h
diff -u src/external/bsd/jemalloc/include/jemalloc/internal/jemalloc_internal_defs.h:1.15 src/external/bsd/jemalloc/include/jemalloc/internal/jemalloc_internal_defs.h:1.16
--- src/external/bsd/jemalloc/include/jemalloc/internal/jemalloc_internal_defs.h:1.15 Mon Sep 23 11:03:45 2024
+++ src/external/bsd/jemalloc/include/jemalloc/internal/jemalloc_internal_defs.h Mon Sep 23 17:08:37 2024
@@ -42,7 +42,11 @@
* total number of bits in a pointer, e.g. on x64, for which the uppermost 16
* bits are the same as bit 47.
*/
+#ifdef _LP64
#define LG_VADDR 48
+#else
+#define LG_VADDR 32
+#endif
/* Defined if C11 atomics are available. */
#define JEMALLOC_C11_ATOMICS
@@ -350,13 +354,20 @@
#define JEMALLOC_HAS_RESTRICT
/* For use by hash code. */
-/* #undef JEMALLOC_BIG_ENDIAN */
+#include <sys/endian.h>
+#if _BYTE_ORDER == _BIG_ENDIAN
+#define JEMALLOC_BIG_ENDIAN
+#endif
/* sizeof(int) == 2^LG_SIZEOF_INT. */
#define LG_SIZEOF_INT 2
/* sizeof(long) == 2^LG_SIZEOF_LONG. */
+#ifdef _LP64
#define LG_SIZEOF_LONG 3
+#else
+#define LG_SIZEOF_LONG 2
+#endif
/* sizeof(long long) == 2^LG_SIZEOF_LONG_LONG. */
#define LG_SIZEOF_LONG_LONG 3