perf: Keep track of the max depth of a callchain
authorFrederic Weisbecker <fweisbec@gmail.com>
Sun, 22 Aug 2010 18:05:22 +0000 (20:05 +0200)
committerFrederic Weisbecker <fweisbec@gmail.com>
Sun, 22 Aug 2010 18:43:17 +0000 (20:43 +0200)
commitd2009c5130b627d3efccae8ed36cd43450c8486d
tree22afece12b12600d9132ab76f8fe74425548351d
parentf4e7ac0a233a4dc9b51345546ab69c64bb43e2c1
perf: Keep track of the max depth of a callchain

In order to implement callchains collapsing, we need to keep
track of the maximum depth in a histogram tree of callchains.
This way we'll avoid allocating an arbitrary temporary buffer
size on callchain merge time.

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>
Cc: Christoph Hellwig <hch@infradead.org>
tools/perf/util/callchain.c
tools/perf/util/callchain.h
tools/perf/util/hist.c
tools/perf/util/sort.h