@@ -26,6 +26,19 @@ any of the following arguments (not a definitive list) to 'configure':
26
26
Embed one or more library paths, so that libjemalloc can find the libraries
27
27
it is linked to. This works only on ELF-based systems.
28
28
29
+ --with-mangling=<map>
30
+ Mangle public symbols specified in <map> which is a comma-separated list of
31
+ name:mangled pairs.
32
+
33
+ For example, to use ld's --wrap option as an alternative method for
34
+ overriding libc's malloc implementation, specify something like:
35
+
36
+ --with-mangling=malloc:__wrap_malloc,free:__wrap_free[...]
37
+
38
+ Note that mangling happens prior to application of the prefix specified by
39
+ --with-jemalloc-prefix, and mangled symbols are then ignored when applying
40
+ the prefix.
41
+
29
42
--with-jemalloc-prefix=<prefix>
30
43
Prefix all public APIs with <prefix>. For example, if <prefix> is
31
44
"prefix_", API changes like the following occur:
@@ -62,8 +75,8 @@ any of the following arguments (not a definitive list) to 'configure':
62
75
Enable assertions and validation code. This incurs a substantial
63
76
performance hit, but is very useful during application development.
64
77
65
- --enable -stats
66
- Enable statistics gathering functionality. See the "opt.stats_print"
78
+ --disable -stats
79
+ Disable statistics gathering functionality. See the "opt.stats_print"
67
80
option documentation for usage details.
68
81
69
82
--enable-prof
@@ -90,51 +103,50 @@ any of the following arguments (not a definitive list) to 'configure':
90
103
Statically link against the specified libunwind.a rather than dynamically
91
104
linking with -lunwind.
92
105
93
- --disable-tiny
94
- Disable tiny (sub-quantum-sized) object support. Technically it is not
95
- legal for a malloc implementation to allocate objects with less than
96
- quantum alignment (8 or 16 bytes, depending on architecture), but in
97
- practice it never causes any problems if, for example, 4-byte allocations
98
- are 4-byte-aligned.
99
-
100
106
--disable-tcache
101
107
Disable thread-specific caches for small objects. Objects are cached and
102
108
released in bulk, thus reducing the total number of mutex operations. See
103
109
the "opt.tcache" option for usage details.
104
110
105
- --enable-swap
106
- Enable mmap()ed swap file support. When this feature is built in, it is
107
- possible to specify one or more files that act as backing store. This
108
- effectively allows for per application swap files.
111
+ --enable-mremap
112
+ Enable huge realloc() via mremap(2). mremap() is disabled by default
113
+ because the flavor used is specific to Linux, which has a quirk in its
114
+ virtual memory allocation algorithm that causes semi-permanent VM map holes
115
+ under normal jemalloc operation.
116
+
117
+ --disable-munmap
118
+ Disable virtual memory deallocation via munmap(2); instead keep track of
119
+ the virtual memory for later use. munmap() is disabled by default (i.e.
120
+ --disable-munmap is implied) on Linux, which has a quirk in its virtual
121
+ memory allocation algorithm that causes semi-permanent VM map holes under
122
+ normal jemalloc operation.
109
123
110
124
--enable-dss
111
125
Enable support for page allocation/deallocation via sbrk(2), in addition to
112
126
mmap(2).
113
127
114
- --enable-fill
115
- Enable support for junk/zero filling of memory. See the "opt.junk"/
116
- "opt.zero" option documentation for usage details.
128
+ --disable-fill
129
+ Disable support for junk/zero filling of memory, quarantine, and redzones.
130
+ See the "opt.junk", "opt.zero", "opt.quarantine", and "opt.redzone" option
131
+ documentation for usage details.
132
+
133
+ --disable-valgrind
134
+ Disable support for Valgrind.
135
+
136
+ --disable-experimental
137
+ Disable support for the experimental API (*allocm()).
138
+
139
+ --enable-utrace
140
+ Enable utrace(2)-based allocation tracing. This feature is not broadly
141
+ portable (FreeBSD has it, but Linux and OS X do not).
117
142
118
143
--enable-xmalloc
119
144
Enable support for optional immediate termination due to out-of-memory
120
145
errors, as is commonly implemented by "xmalloc" wrapper function for malloc.
121
146
See the "opt.xmalloc" option documentation for usage details.
122
147
123
- --enable-sysv
124
- Enable support for System V semantics, wherein malloc(0) returns NULL
125
- rather than a minimal allocation. See the "opt.sysv" option documentation
126
- for usage details.
127
-
128
- --enable-dynamic-page-shift
129
- Under most conditions, the system page size never changes (usually 4KiB or
130
- 8KiB, depending on architecture and configuration), and unless this option
131
- is enabled, jemalloc assumes that page size can safely be determined during
132
- configuration and hard-coded. Enabling dynamic page size determination has
133
- a measurable impact on performance, since the compiler is forced to load
134
- the page size from memory rather than embedding immediate values.
135
-
136
- --disable-lazy-lock
137
- Disable code that wraps pthread_create() to detect when an application
148
+ --enable-lazy-lock
149
+ Enable code that wraps pthread_create() to detect when an application
138
150
switches from single-threaded to multi-threaded mode, so that it can avoid
139
151
mutex locking/unlocking operations while in single-threaded mode. In
140
152
practice, this feature usually has little impact on performance unless
@@ -181,11 +193,24 @@ PATH="?"
181
193
182
194
=== Advanced compilation =======================================================
183
195
196
+ To build only parts of jemalloc, use the following targets:
197
+
198
+ build_lib_shared
199
+ build_lib_static
200
+ build_lib
201
+ build_doc_html
202
+ build_doc_man
203
+ build_doc
204
+
184
205
To install only parts of jemalloc, use the following targets:
185
206
186
207
install_bin
187
208
install_include
209
+ install_lib_shared
210
+ install_lib_static
188
211
install_lib
212
+ install_doc_html
213
+ install_doc_man
189
214
install_doc
190
215
191
216
To clean up build results to varying degrees, use the following make targets:
@@ -248,10 +273,6 @@ directory, issue configuration and build commands:
248
273
249
274
The manual page is generated in both html and roff formats. Any web browser
250
275
can be used to view the html manual. The roff manual page can be formatted
251
- prior to installation via any of the following commands :
276
+ prior to installation via the following command :
252
277
253
278
nroff -man -t doc/jemalloc.3
254
-
255
- groff -man -t -Tps doc/jemalloc.3 | ps2pdf - doc/jemalloc.3.pdf
256
-
257
- (cd doc; groff -man -man-ext -t -Thtml jemalloc.3 > jemalloc.3.html)
0 commit comments