Skip to content
Snippets Groups Projects
Commit 5fcd0f09 authored by Peter Cai's avatar Peter Cai
Browse files

Add perf record support for fstack

parent 9555e08c
No related branches found
No related tags found
No related merge requests found
...@@ -2,12 +2,29 @@ source "$EXP_ROOT/experiments/nginx.shared.sh" ...@@ -2,12 +2,29 @@ source "$EXP_ROOT/experiments/nginx.shared.sh"
pre_start() { pre_start() {
nginx_pre_start nginx_pre_start
while [ ! -z "$1" ]; do
case "$1" in
--perf-record)
PERF_RECORD_TYPE="$2"
EXPERIMENT_NAME_EXT="perf_$PERF_RECORD_TYPE.$EXPERIMENT_NAME_EXT"
shift
shift
;;
*)
echo "Unknown option"
exit 1
;;
esac
done
} }
run_exp() { run_exp() {
nginx_start nginx_start
nginx_warmup nginx_warmup
[ ! -z "$PERF_RECORD_TYPE" ] && perf_record_start
nginx_bench 10000 nginx_bench 10000
[ ! -z "$PERF_RECORD_TYPE" ] && perf_record_stop
nginx_stop nginx_stop
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment