From 1dae7b5436ac88c6ffc7768dd625af2419d320d4 Mon Sep 17 00:00:00 2001 From: Henning Baldersheim Date: Fri, 13 May 2022 12:10:26 +0000 Subject: Use explicit VESPA_LOAD_CODE_AS_HUGEPAGES --- vespabase/src/start-cbinaries.sh | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) (limited to 'vespabase') diff --git a/vespabase/src/start-cbinaries.sh b/vespabase/src/start-cbinaries.sh index ecd673629d8..fa732d6bda8 100755 --- a/vespabase/src/start-cbinaries.sh +++ b/vespabase/src/start-cbinaries.sh @@ -152,6 +152,9 @@ configure_vespa_malloc () { tryfile="${VESPA_HOME}/${pre}/${suf}" if [ -f "$tryfile" ]; then LD_PRELOAD="$tryfile" + if [ "$VESPA_LOAD_CODE_AS_HUGEPAGES" ]; then + LD_PRELOAD="$LD_PRELOAD:"${VESPA_HOME}/${pre}/vespa/malloc/libvespa_load_as_huge.so" + fi if [ "$VESPA_USE_HUGEPAGES" ]; then export VESPA_MALLOC_HUGEPAGES="$VESPA_USE_HUGEPAGES" log_debug_message "enabling hugepages for '$0-bin'." @@ -162,17 +165,10 @@ configure_vespa_malloc () { fi } -configure_preload() { - if [ "$PRELOAD" ]; then - LD_PRELOAD="$LD_PRELOAD:$PRELOAD" - fi -} - configure_valgrind configure_huge_pages configure_use_madvise configure_vespa_malloc -configure_preload log_debug_message "Using LD_PRELOAD='$LD_PRELOAD'" -- cgit v1.2.3