@@ -270,7 +270,9 @@ function gg_run_ctest_with_model_debug {
270270 local model; model=$( gg_get_model)
271271 cd build-ci-debug
272272 set -e
273+
273274 (LLAMACPP_TEST_MODELFILE=" $model " time ctest --output-on-failure -L model) 2>&1 | tee -a $OUT /${ci} -ctest.log
275+
274276 set +e
275277 cd ..
276278}
@@ -281,7 +283,15 @@ function gg_run_ctest_with_model_release {
281283 local model; model=$( gg_get_model)
282284 cd build-ci-release
283285 set -e
286+
284287 (LLAMACPP_TEST_MODELFILE=" $model " time ctest --output-on-failure -L model) 2>&1 | tee -a $OUT /${ci} -ctest.log
288+
289+ # test memory leaks
290+ # if [[ ! -z ${GG_BUILD_METAL} ]]; then
291+ # # TODO: this hangs for some reason ...
292+ # (time leaks -quiet -atExit -- ./bin/test-thread-safety -m $model --parallel 2 -t 2 -p "hello") 2>&1 | tee -a $OUT/${ci}-leaks.log
293+ # fi
294+
285295 set +e
286296 cd ..
287297}
@@ -386,10 +396,10 @@ function gg_run_open_llama_7b_v2 {
386396
387397 (time ./bin/llama-imatrix --model ${model_f16} -f ${wiki_test} -t 1 -ngl 99 -c 2048 -b 512 --chunks 4 ) 2>&1 | tee -a $OUT /${ci} -imatrix.log
388398
389- (time ./bin/llama-save-load-state --model ${model_q4_0} -ngl 10 -c 0 ) 2>&1 | tee -a $OUT /${ci} -save-load-state.log
390- (time ./bin/llama-save-load-state --model ${model_q4_0} -ngl 10 -c 0 -fa ) 2>&1 | tee -a $OUT /${ci} -save-load-state.log
391- (time ./bin/llama-save-load-state --model ${model_q4_0} -ngl 99 -c 0 ) 2>&1 | tee -a $OUT /${ci} -save-load-state.log
392- (time ./bin/llama-save-load-state --model ${model_q4_0} -ngl 99 -c 0 -fa ) 2>&1 | tee -a $OUT /${ci} -save-load-state.log
399+ (time ./bin/llama-save-load-state --model ${model_q4_0} -ngl 10 -c 0 -fa off ) 2>&1 | tee -a $OUT /${ci} -save-load-state.log
400+ (time ./bin/llama-save-load-state --model ${model_q4_0} -ngl 10 -c 0 -fa on ) 2>&1 | tee -a $OUT /${ci} -save-load-state.log
401+ (time ./bin/llama-save-load-state --model ${model_q4_0} -ngl 99 -c 0 -fa off ) 2>&1 | tee -a $OUT /${ci} -save-load-state.log
402+ (time ./bin/llama-save-load-state --model ${model_q4_0} -ngl 99 -c 0 -fa on ) 2>&1 | tee -a $OUT /${ci} -save-load-state.log
393403
394404 function check_ppl {
395405 qnt=" $1 "
@@ -520,8 +530,8 @@ function gg_run_pythia_1_4b {
520530
521531 (time ./bin/llama-imatrix --model ${model_f16} -f ${wiki_test_60} -ngl 99 -c 128 -b 128 --chunks 1 ) 2>&1 | tee -a $OUT /${ci} -imatrix.log
522532
523- (time ./bin/llama-save-load-state --model ${model_q4_0} -ngl 99 -c 0 ) 2>&1 | tee -a $OUT /${ci} -save-load-state.log
524- (time ./bin/llama-save-load-state --model ${model_q4_0} -ngl 99 -c 0 -fa ) 2>&1 | tee -a $OUT /${ci} -save-load-state.log
533+ (time ./bin/llama-save-load-state --model ${model_q4_0} -ngl 99 -c 0 -fa off ) 2>&1 | tee -a $OUT /${ci} -save-load-state.log
534+ (time ./bin/llama-save-load-state --model ${model_q4_0} -ngl 99 -c 0 -fa on ) 2>&1 | tee -a $OUT /${ci} -save-load-state.log
525535
526536 function check_ppl {
527537 qnt=" $1 "
@@ -651,10 +661,10 @@ function gg_run_pythia_2_8b {
651661
652662 (time ./bin/llama-imatrix --model ${model_f16} -f ${wiki_test} -t 1 -ngl 99 -c 2048 -b 512 --chunks 4 ) 2>&1 | tee -a $OUT /${ci} -imatrix.log
653663
654- (time ./bin/llama-save-load-state --model ${model_q4_0} -ngl 10 -c 0 ) 2>&1 | tee -a $OUT /${ci} -save-load-state.log
655- (time ./bin/llama-save-load-state --model ${model_q4_0} -ngl 10 -c 0 -fa ) 2>&1 | tee -a $OUT /${ci} -save-load-state.log
656- (time ./bin/llama-save-load-state --model ${model_q4_0} -ngl 99 -c 0 ) 2>&1 | tee -a $OUT /${ci} -save-load-state.log
657- (time ./bin/llama-save-load-state --model ${model_q4_0} -ngl 99 -c 0 -fa ) 2>&1 | tee -a $OUT /${ci} -save-load-state.log
664+ (time ./bin/llama-save-load-state --model ${model_q4_0} -ngl 10 -c 0 -fa off ) 2>&1 | tee -a $OUT /${ci} -save-load-state.log
665+ (time ./bin/llama-save-load-state --model ${model_q4_0} -ngl 10 -c 0 -fa on ) 2>&1 | tee -a $OUT /${ci} -save-load-state.log
666+ (time ./bin/llama-save-load-state --model ${model_q4_0} -ngl 99 -c 0 -fa off ) 2>&1 | tee -a $OUT /${ci} -save-load-state.log
667+ (time ./bin/llama-save-load-state --model ${model_q4_0} -ngl 99 -c 0 -fa on ) 2>&1 | tee -a $OUT /${ci} -save-load-state.log
658668
659669 function check_ppl {
660670 qnt=" $1 "
@@ -860,20 +870,15 @@ if [ -z ${GG_BUILD_LOW_PERF} ]; then
860870fi
861871
862872ret=0
863- if [ -z ${GG_BUILD_SYCL} ]; then
864- # SYCL build breaks with debug build flags
865- test $ret -eq 0 && gg_run ctest_debug
866- fi
873+ test $ret -eq 0 && gg_run ctest_debug
867874test $ret -eq 0 && gg_run ctest_release
868875
869876if [ -z ${GG_BUILD_LOW_PERF} ]; then
870877 test $ret -eq 0 && gg_run embd_bge_small
871878 test $ret -eq 0 && gg_run rerank_tiny
872879
873880 if [ -z ${GG_BUILD_CLOUD} ] || [ ${GG_BUILD_EXTRA_TESTS_0} ]; then
874- if [ -z ${GG_BUILD_SYCL} ]; then
875- test $ret -eq 0 && gg_run test_scripts_debug
876- fi
881+ test $ret -eq 0 && gg_run test_scripts_debug
877882 test $ret -eq 0 && gg_run test_scripts_release
878883 fi
879884
@@ -884,9 +889,7 @@ if [ -z ${GG_BUILD_LOW_PERF} ]; then
884889 test $ret -eq 0 && gg_run pythia_2_8b
885890 # test $ret -eq 0 && gg_run open_llama_7b_v2
886891 fi
887- if [ -z ${GG_BUILD_SYCL} ]; then
888- test $ret -eq 0 && gg_run ctest_with_model_debug
889- fi
892+ test $ret -eq 0 && gg_run ctest_with_model_debug
890893 test $ret -eq 0 && gg_run ctest_with_model_release
891894 fi
892895fi
0 commit comments