]> git.baikalelectronics.ru Git - kernel.git/commit
perf tools: Fix "Command" sort_entry's cmp and collapse function
authorJiri Olsa <jolsa@kernel.org>
Fri, 15 May 2015 15:54:28 +0000 (17:54 +0200)
committerArnaldo Carvalho de Melo <acme@redhat.com>
Fri, 15 May 2015 20:02:21 +0000 (17:02 -0300)
commit9bc9cd94170d1c636c6aac81c42e72082f6dc374
tree43d894077cc5e1eb460ce24d528a1c36e9795d57
parent0aecc0e8cda03e5cc2c621215906fb59fff64738
perf tools: Fix "Command" sort_entry's cmp and collapse function

Currently the se_cmp and se_collapse use pointer comparison,
which is ok for for testing equality of strings. It's not ok
as comparing function for rbtree insertion, because it gives
different results based on current pointer values.

We saw test 32 (hists cumulation test) failing based on different
environment setup. Having all sort functions straightened fix the
test for us.

Reported-by: Jan Stancek <jstancek@redhat.com>
Signed-off-by: Jiri Olsa <jolsa@kernel.org>
Cc: David Ahern <dsahern@gmail.com>
Cc: Jan Stancek <jstancek@redhat.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
tools/perf/util/sort.c