From fc1c9aafe6da9553713ff0b6e491d9aa77b448a8 Mon Sep 17 00:00:00 2001 From: Michal Berger Date: Wed, 21 Sep 2022 09:41:24 +0200 Subject: [PATCH] perf/vhost: Allow to only generate the fio configuration This use case was missed during the initial refactor introduced via 008f8a8617. CI depends on it so allow to specify the target location of the fio configuration and allow to skip call to the main perf wrapper. Signed-off-by: Michal Berger Change-Id: Ie41f9db40769980047f42475ce74e61c374c364c Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/14590 Tested-by: SPDK CI Jenkins Reviewed-by: Konrad Sztyber Reviewed-by: Karol Latecki Reviewed-by: Jim Harris --- scripts/perf/vhost/run_vhost_test.sh | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/scripts/perf/vhost/run_vhost_test.sh b/scripts/perf/vhost/run_vhost_test.sh index da6955d0c..5386497da 100755 --- a/scripts/perf/vhost/run_vhost_test.sh +++ b/scripts/perf/vhost/run_vhost_test.sh @@ -65,9 +65,12 @@ if [[ -n $extra_params ]]; then perf_args+=($extra_params) fi -trap 'rm -f "$curdir/fio.conf"' EXIT +out_fio_conf=${out_fio_conf:-$curdir/fio.conf} +fio_conf > "$out_fio_conf" -fio_conf > "$curdir/fio.conf" +[[ -z $only_fio_conf ]] || exit 0 + +trap 'rm -f "$out_fio_conf"' EXIT "$rootdir/test/vhost/perf_bench/vhost_perf.sh" \ - "${perf_args[@]}" --fio-jobs="$curdir/fio.conf"${fio_jobs:+",$fio_jobs"} + "${perf_args[@]}" --fio-jobs="$out_fio_conf"${fio_jobs:+",$fio_jobs"}