]> git.karo-electronics.de Git - karo-tx-linux.git/commit
perf: Initialize callchains roots's childen hits
authorFrederic Weisbecker <fweisbec@gmail.com>
Sun, 22 Aug 2010 02:29:17 +0000 (04:29 +0200)
committerGreg Kroah-Hartman <gregkh@suse.de>
Mon, 20 Sep 2010 20:17:55 +0000 (13:17 -0700)
commita4bc94d437129f5c5fe64b1f58691a6e8d113e74
tree7a15fb033c14115854730b3bdf92a9496871052c
parent05e0120a463a8ce6337a6e4d6721a7b3aef8c52c
perf: Initialize callchains roots's childen hits

commit 5225c45899e872383ca39f5533d28ec63c54b39e upstream.

Each histogram entry has a callchain root that stores the
callchain samples. However we forgot to initialize the
tracking of children hits of these roots, which then got
random values on their creation.

The root children hits is multiplied by the minimum percentage
of hits provided by the user, and the result becomes the minimum
hits expected from children branches. If the random value due
to the uninitialization is big enough, then this minimum number
of hits can be huge and eventually filter every children branches.

The end result was invisible callchains. All we need to
fix this is to initialize the children hits of the root.

Reported-by: Christoph Hellwig <hch@infradead.org>
Signed-off-by: Frederic Weisbecker <fweisbec@gmail.com>
Cc: Ingo Molnar <mingo@elte.hu>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Arnaldo Carvalho de Melo <acme@redhat.com>
Cc: Paul Mackerras <paulus@samba.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
tools/perf/util/callchain.h