From 4d432b42d4c4a3cccaf4f9e8e8258ece6fc4841c Mon Sep 17 00:00:00 2001 From: denes Date: Mon, 7 Oct 2019 11:30:45 +0200 Subject: [PATCH] Publishing tests.png and flamegraph.svg --- Jenkinsfile | 5 ++++- generate_flame_graph.sh | 4 ++-- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index 689016d..13fc29e 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -17,7 +17,10 @@ pipeline { stage('Running catch2 tests') { steps { - sh './performance_measuring_test' + sh './performance_measuring_test > tests.txt' + sh 'convert -size 360x360 xc:white -font "FreeMon" -pointsize 12 -fill black -draw @tests.txt tests.png' + sh 'convert -background black -fill white -pointsize 16 -font Courier label:tests.txt tests.png' + archiveArtifacts artifacts: 'tests.png', fingerprint: true } } diff --git a/generate_flame_graph.sh b/generate_flame_graph.sh index 913635d..004ece9 100755 --- a/generate_flame_graph.sh +++ b/generate_flame_graph.sh @@ -1,9 +1,9 @@ #/bin/bash -# Don't forget to : +# Don't forget to allow perf record run as user: # sudo bash -c "echo 0 > /proc/sys/kernel/perf_event_paranoid" perf record -F 20000 -g ./performance_measuring perf script > out.perf -./FlameGraph/stackcollapse-perf.pl out.perf > out.folded +./FlameGraph/stackcollapse-perf.pl --all out.perf > out.folded ./FlameGraph/flamegraph.pl out.folded > flamegraph.svg