aboutsummaryrefslogtreecommitdiffstats
path: root/tools/perf/scripts/python/stackcollapse.py
diff options
context:
space:
mode:
authorVeronika Molnarova <vmolnaro@redhat.com>2023-09-19 17:02:42 +0200
committerNamhyung Kim <namhyung@kernel.org>2023-09-21 11:53:45 -0700
commitfa52d995d1d0b64e75f63571df2e57ba22ff0cb1 (patch)
tree74507571d6808a796cd4dc59775cbfd24a869673 /tools/perf/scripts/python/stackcollapse.py
parentperf jevents: fix no member named 'entries' issue (diff)
downloadlinux-fa52d995d1d0b64e75f63571df2e57ba22ff0cb1.tar.gz
linux-fa52d995d1d0b64e75f63571df2e57ba22ff0cb1.zip
perf test stat+shadow_stat.sh: Add threshold for rounding errors
The test was failing in specific scenarios due to imperfection of FP arithmetics. The `bc` command wasn't correctly rounding the result of division causing the failure. Replace the `bc` with `awk` which should work with more decimal places and add a threshold to catch any possible rounding errors. The acceptable rounding error is set to 0.01 when the test passes with a warning message. Signed-off-by: Veronika Molnarova <vmolnaro@redhat.com> Acked-by: Michael Petlan <mpetlan@redhat.com> Link: https://lore.kernel.org/r/20230919150419.23193-1-vmolnaro@redhat.com Signed-off-by: Namhyung Kim <namhyung@kernel.org>
Diffstat (limited to 'tools/perf/scripts/python/stackcollapse.py')
0 files changed, 0 insertions, 0 deletions