Skip to content

Commit a26c4cc

Browse files
authored
scripts : add option to compare commits in Debug (#13806)
* scripts : add option to compare commits in Debug * cont : reuse existing CMAKE_OPTS
1 parent 4265a87 commit a26c4cc

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

scripts/compare-commits.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,14 +17,14 @@ rm -f llama-bench.sqlite > /dev/null
1717

1818
# to test a backend, call the script with the corresponding environment variable (e.g. GGML_CUDA=1 ./scripts/compare-commits.sh ...)
1919
if [ -n "$GGML_CUDA" ]; then
20-
cmake_opts="-DGGML_CUDA=ON"
20+
CMAKE_OPTS="${CMAKE_OPTS} -DGGML_CUDA=ON"
2121
fi
2222

2323
dir="build-bench"
2424

2525
function run {
2626
rm -fr ${dir} > /dev/null
27-
cmake -B ${dir} -S . $cmake_opts > /dev/null
27+
cmake -B ${dir} -S . ${CMAKE_OPTS} > /dev/null
2828
cmake --build ${dir} -t llama-bench > /dev/null
2929
${dir}/bin/llama-bench -o sql -oe md $bench_args | sqlite3 llama-bench.sqlite
3030
}

0 commit comments

Comments
 (0)