compatibility with apps using mallopt?
normalperson at yhbt.net
Sun Nov 17 14:47:33 PST 2013
Hi, I'd like to continue providing the option of using jemalloc (and
other alternative malloc implementations) to glibc/Linux users of
I have a pending change in cmogstored.git which adds mallopt(3)
support. This needed for good out-of-the-box VM usage on modern glibc
and many disk-bound threads. cmogstored is not at all dependent on
malloc performance/scalability, so glibc malloc defaults clash greatly
with the design of cmogstored.
When I ./configure with LIBS=-ljemalloc, things go bad because the
mallopt call is still detected and going to glibc even though the glibc
malloc implementation is not used/linked.
So my question is: what's the best way to avoid mallopt() when using
glibc if cmogstored is linked to jemalloc (or any non-glibc malloc)?
Or should jemalloc provide a mallopt() function which may
wrap mallctl() in some cases and/or just do nothing at all?
Thanks for reading.
 - http://bogomips.org/cmogstored/README
 - http://bogomips.org/cmogstored.git/patch?id=ebf312e250ff
More information about the jemalloc-discuss