gecko-dev/memory/build
Mike Hommey 19448fe709 Bug 1356701 - Export unprefixed malloc and duplication functions on OSX. r=njn
Going through the system zone allocator for every call to realloc/free
on OSX is costly, because the zone allocator needs to first verify that
the allocations do belong to the allocator it invokes (which ends up
calling jemalloc's malloc_usable_size), which is unnecessary when we
expect the allocations to belong to jemalloc.

So, we export the malloc/realloc/free/etc. symbols from
libmozglue.dylib, such that libraries and programs linked against it
call directly into jemalloc instead of going through the system zone
allocator, effectively shortcutting the allocator verification.

The risk is that some things in Gecko try to realloc/free pointers it
got from system libraries, if those were allocated with a system zone
that is not jemalloc.

--HG--
extra : rebase_source : ee0b29e1275176f52e64f4648dfa7ce25d61292e
2017-07-04 15:01:50 +09:00
..
jemalloc_config.cpp Bug 1363992 - Remove support for making jemalloc4 the default. r=njn 2017-05-11 13:16:00 +09:00
malloc_decls.h Bug 1368932 - Remove void argument from declarations in malloc_decls.h. r=njn 2017-05-25 13:56:40 +09:00
moz.build Bug 1363992 - Remove support for making jemalloc4 the default. r=njn 2017-05-11 13:16:00 +09:00
mozmemory.h Bug 1365473 - Rename jemalloc_types.h to mozjemalloc_types.h. r=njn 2017-05-12 21:52:25 +09:00
mozmemory_wrap.c Bug 1356701 - Export unprefixed malloc and duplication functions on OSX. r=njn 2017-07-04 15:01:50 +09:00
mozmemory_wrap.h Bug 1356701 - Export unprefixed malloc and duplication functions on OSX. r=njn 2017-07-04 15:01:50 +09:00
replace_malloc.c Bug 1368932 - Handle missing replace_posix_memalign at the replace-malloc level. r=njn 2017-05-31 13:47:17 +09:00
replace_malloc.h Bug 1368932 - Handle missing replace_posix_memalign at the replace-malloc level. r=njn 2017-05-31 13:47:17 +09:00
replace_malloc_bridge.h Bug 1182996 - Fix and add missing namespace comments. rs=ehsan 2015-07-13 08:25:42 -07:00
zone.c Bug 1356701 - Export unprefixed malloc and duplication functions on OSX. r=njn 2017-07-04 15:01:50 +09:00