diff options
author | Rafael J. Wysocki <rjw@sisk.pl> | 2009-08-10 23:40:50 +0200 |
---|---|---|
committer | Rafael J. Wysocki <rjw@sisk.pl> | 2009-08-10 23:40:50 +0200 |
commit | dcbf77cac640af0ab944d5cbb07934bf6708b4d9 (patch) | |
tree | e2f4d1b3a1089ee10436cb19740a9cb99f2dc527 /tools/perf/util/callchain.h | |
parent | c00aafcd4977769e8728292302ddbbb8b1082fab (diff) | |
parent | 85dfd81dc57e8183a277ddd7a56aa65c96f3f487 (diff) |
Merge branch 'master' into for-linus
Diffstat (limited to 'tools/perf/util/callchain.h')
-rw-r--r-- | tools/perf/util/callchain.h | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/tools/perf/util/callchain.h b/tools/perf/util/callchain.h index 7812122bea1..a926ae4f5a1 100644 --- a/tools/perf/util/callchain.h +++ b/tools/perf/util/callchain.h @@ -7,6 +7,7 @@ #include "symbol.h" enum chain_mode { + CHAIN_NONE, CHAIN_FLAT, CHAIN_GRAPH_ABS, CHAIN_GRAPH_REL @@ -21,7 +22,7 @@ struct callchain_node { struct rb_root rb_root; /* sorted tree of children */ unsigned int val_nr; u64 hit; - u64 cumul_hit; /* hit + hits of children */ + u64 children_hit; }; struct callchain_param; @@ -48,6 +49,11 @@ static inline void callchain_init(struct callchain_node *node) INIT_LIST_HEAD(&node->val); } +static inline u64 cumul_hits(struct callchain_node *node) +{ + return node->hit + node->children_hit; +} + int register_callchain_param(struct callchain_param *param); void append_chain(struct callchain_node *root, struct ip_callchain *chain, struct symbol **syms); |