From: Philippe Waroquiers Date: Sun, 27 Jan 2019 10:15:30 +0000 (+0100) Subject: Fix callgrind_annotate non deterministic order for equal total X-Git-Tag: VALGRIND_3_15_0~87 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=50f76c756a09b33c7d0cd7efbb8ad38cc903ab93;p=thirdparty%2Fvalgrind.git Fix callgrind_annotate non deterministic order for equal total Patch by Matthias Schwarzott --- diff --git a/NEWS b/NEWS index b69875efb5..95970ce6d3 100644 --- a/NEWS +++ b/NEWS @@ -90,6 +90,7 @@ where XXXXXX is the bug number as listed below. 403552 s390x: wrong facility bit checked for vector facility n-i-bz add syswrap for PTRACE_GET|SET_THREAD_AREA on amd64. +n-i-bz Fix callgrind_annotate non deterministic order for equal total Release 3.14.0 (9 October 2018) ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ diff --git a/callgrind/callgrind_annotate.in b/callgrind/callgrind_annotate.in index ebf81a0be9..1aa8e07b13 100644 --- a/callgrind/callgrind_annotate.in +++ b/callgrind/callgrind_annotate.in @@ -921,7 +921,7 @@ sub print_summary_and_fn_totals () # Sort function names into order dictated by --sort option. @fn_fullnames = sort { - mycmp($fn_totals{$a}, $fn_totals{$b}) + mycmp($fn_totals{$a}, $fn_totals{$b}) || $a cmp $b } @fn_fullnames;