Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion bench.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
# Allocators and tests
# --------------------------------------------------------------------

readonly alloc_all="sys dh ff fg gd hd hm hml iso je lf lp lt mi mi-sec mi2 mi2-sec mng mesh nomesh pa rp sc scudo sg sm sn sn-sec tbb tc tcg mi-dbg mi2-dbg xmi xsmi xmi-dbg yal"
readonly alloc_all="sys dh ff fg gd hd hm hml iso je lf lp lt mi mi-sec mi2 mi2-sec mng mesh nomesh pa rp sc scudo sg sm sn sn-sec tbb tc tcg mi-dbg mi2-dbg xmi xsmi xmi-dbg yal rmalloc"
readonly alloc_secure="dh ff gd hm hml iso mi-sec mi2-sec mng pa scudo sg sn-sec sg"
alloc_run="" # allocators to run (expanded by command line options)
alloc_installed="sys" # later expanded to include all installed allocators
Expand Down Expand Up @@ -125,6 +125,7 @@ alloc_lib_add "tbb" "$lib_tbb"
alloc_lib_add "tc" "$localdevdir/tc/.libs/libtcmalloc_minimal$extso"
alloc_lib_add "tcg" "$localdevdir/tcg/bazel-bin/tcmalloc/libtcmalloc$extso"
alloc_lib_add "yal" "$localdevdir/yal/yalloc$extso"
alloc_lib_add "rmalloc" "$localdevdir/rmalloc/lib/librmalloc$extso"

alloc_lib_add "mi" "$localdevdir/mi/out/release/libmimalloc$extso"
alloc_lib_add "mi-sec" "$localdevdir/mi/out/secure/libmimalloc-secure$extso"
Expand Down
13 changes: 13 additions & 0 deletions build-bench-env.sh
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,7 @@ readonly version_tbb=v2021.9.0
readonly version_tc=gperftools-2.18
readonly version_tcg=81f4e44f23f2936303f9404fee7315119b9df623 # 2026-02-23
readonly version_yal=main
readonly version_rmalloc=master

# benchmark versions
readonly version_redis=6.2.7
Expand Down Expand Up @@ -104,6 +105,7 @@ setup_tbb=0
setup_tc=0
setup_tcg=0
setup_yal=0
setup_rmalloc=0

# bigger benchmarks
setup_bench=0
Expand Down Expand Up @@ -147,6 +149,7 @@ while : ; do
setup_tbb=$flag_arg
setup_tc=$flag_arg
setup_yal=$flag_arg
setup_rmalloc=$flag_arg
if [ -z "$darwin" ]; then
setup_tcg=$flag_arg # lacking 'malloc.h'
setup_dh=$flag_arg
Expand Down Expand Up @@ -176,6 +179,8 @@ while : ; do
;;
bench)
setup_bench=$flag_arg;;
rmalloc)
setup_rmalloc=$flag_arg;;
ff)
setup_ff=$flag_arg;;
fg)
Expand Down Expand Up @@ -280,6 +285,7 @@ while : ; do
echo " tc setup tcmalloc ($version_tc)"
echo " tcg setup Google's tcmalloc ($version_tcg)"
echo " yal setup yalloc ($version_yal)"
echo " rmalloc setup rmalloc($version_rmalloc)"
echo ""
echo " bench build all local benchmarks"
echo " lean setup lean 3 benchmark"
Expand Down Expand Up @@ -467,6 +473,13 @@ if test "$setup_packages" = "1"; then
fi
fi

if test "$setup_rmalloc" = "1"; then
checkout rmalloc $version_rmalloc https://github.com/newell-romario/rmalloc
cmake -DCMAKE_BUILD_TYPE=RELEASE .
make
popd
fi

if test "$setup_hm" = "1"; then
checkout hm $version_hm https://github.com/GrapheneOS/hardened_malloc
make CONFIG_NATIVE=true CONFIG_WERROR=false VARIANT=light -j $proc
Expand Down
Loading