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

Add perf stat support

parent 362591fb
No related branches found
No related tags found
No related merge requests found
......@@ -2,4 +2,5 @@ IS_CUSTOM_KERNEL=true
KERNEL_SRC=/home/p5cai/workspace/linux
CPUPOWER=$KERNEL_SRC/tools/power/cpupower/cpupower
X86_ENERGY_PERF_POLICY=$KERNEL_SRC/tools/power/x86/x86_energy_perf_policy/x86_energy_perf_policy
PERF=$KERNEL_SRC/tools/perf/perf
export LD_LIBRARY_PATH="$LD_LIBRARY_PATH":"$KERNEL_SRC/tools/power/cpupower"
IS_CUSTOM_KERNEL=false
CPUPOWER=cpupower
X86_ENERGY_PERF_POLICY=x86_energy_perf_policy
PERF=perf
# Execute all SSH commands under this user
# so that we don't need ssh keys for root
......
source "$EXP_ROOT/experiments/perf.shared.sh"
CONNS=160 # per agent thread
load_config() {
......@@ -37,7 +39,9 @@ warmup() {
run_mutilate() {
echo "Running mutilate with $CONNS connections per agent (core) and QPS = $QPS"
perf_stat_start "$1"
sudo -u $SSH_USER $MUTILATE --noload -c$CONNS $MUTCLIENTS -t30 -u 0 -q $QPS | tee $DATA_OUT/$1.txt
perf_stat_stop
}
memcached_pre_start() {
......
perf_stat_start() {
$PERF stat -C 0-$((THREADS - 1)) -e LLC-load-misses:u,LLC-load-misses:k,mem_load_uops_retired.llc_miss,mem_uops_retired.all_loads,cycles,cycles:u,cycles:k,instructions,instructions:u,instructions:k,stalled-cycles-frontend,stalled-cycles-backend -o "$DATA_OUT/stat_$1.txt" &
PERF_STAT_PID=$!
}
perf_stat_stop() {
kill -INT "$PERF_STAT_PID" || true
}
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