Skip to content

Instantly share code, notes, and snippets.

/jemalloc-hoard-malloc.md Secret
Created Jul 26, 2015

Embed
What would you like to do?
benchmark memory allocators: jemalloc-3.6.0 / Hoard-2015 / libc-malloc

Mac OS X 10.11

memory alloc. single-threaded multi-threaded (4)
Jemalloc-3.6.0 7244770 24287999
Hoard-2015 9887913 37266817
libc-malloc 6841766 22107574

Ubuntu 15.04 (vivid)

memory alloc. single-threaded multi-threaded (2)
Jemalloc-3.6.0 10371523 19734297
Hoard-2015 11529058 21889318
libc-malloc 8534478 17111621
  • Mac OSX:
   # Mach-O (64-bit), Dynamic Libraries
   make darwin -C src/
   make -C benchmarks

   # jemalloc
   single-threaded: DYLD_INSERT_LIBRARIES=libjemalloc.dylib benchmarks/larson/larson 10 7 8 10000 1000 1 1 1
   multi-threaded (2): DYLD_INSERT_LIBRARIES=libjemalloc.dylib benchmarks/larson/larson 10 7 8 10000 1000 1 2 2
   multi-threaded (4): DYLD_INSERT_LIBRARIES=libjemalloc.dylib benchmarks/larson/larson 10 7 8 10000 1000 1 4 4
   # hoard
   single-threaded: DYLD_INSERT_LIBRARIES=libhoard.dylib benchmarks/larson/larson 10 7 8 10000 1000 1 1 1
   multi-threaded (2): DYLD_INSERT_LIBRARIES=libhoard.dylib benchmarks/larson/larson 10 7 8 10000 1000 1 2 2
   multi-threaded (4): DYLD_INSERT_LIBRARIES=libhoard.dylib benchmarks/larson/larson 10 7 8 10000 1000 1 4 4
   # libc malloc
   single-threaded: benchmarks/larson/larson 10 7 8 10000 1000 1 1 1
   multi-threaded (2): benchmarks/larson/larson 10 7 8 10000 1000 1 2 2
   multi-threaded (4): benchmarks/larson/larson 10 7 8 10000 1000 1 4 4
  • Linux
   # x86-64 (amd64)
   make linux-gcc-x86-64 -C src/
   # x86 (i386)
   linux-gcc-x86 -C src/
   # build benchmarks
   make -C benchmarks

   # jemalloc
   single-threaded: LD_PRELOAD=libjemalloc.so benchmarks/larson/larson 10 7 8 10000 1000 1 1 1
   multi-threaded (2): LD_PRELOAD=libjemalloc.so benchmarks/larson/larson 10 7 8 10000 1000 1 2 2
   multi-threaded (4): LD_PRELOAD=libjemalloc.so benchmarks/larson/larson 10 7 8 10000 1000 1 4 4
   # hoard
   single-threaded: LD_PRELOAD=libhoard.so benchmarks/larson/larson 10 7 8 10000 1000 1 1 1
   multi-threaded (2): LD_PRELOAD=libhoard.so benchmarks/larson/larson 10 7 8 10000 1000 1 2 2
   multi-threaded (4): LD_PRELOAD=libhoard.so benchmarks/larson/larson 10 7 8 10000 1000 1 4 4
   # libc malloc
   single-threaded: benchmarks/larson/larson 10 7 8 10000 1000 1 1 1
   multi-threaded (2): benchmarks/larson/larson 10 7 8 10000 1000 1 2 2
   multi-threaded (4): benchmarks/larson/larson 10 7 8 10000 1000 1 4 4
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.