Lines Matching refs:cursor

572 fill_node(struct callchain_node *node, struct callchain_cursor *cursor)  in fill_node()  argument
576 node->val_nr = cursor->nr - cursor->pos; in fill_node()
580 cursor_node = callchain_cursor_current(cursor); in fill_node()
629 callchain_cursor_advance(cursor); in fill_node()
630 cursor_node = callchain_cursor_current(cursor); in fill_node()
637 struct callchain_cursor *cursor, in add_child() argument
646 if (fill_node(new, cursor) < 0) { in add_child()
796 struct callchain_cursor *cursor, in split_add_child() argument
828 if (idx_total < cursor->nr) { in split_add_child()
839 node = callchain_cursor_current(cursor); in split_add_child()
840 new = add_child(parent, cursor, period); in split_add_child()
869 struct callchain_cursor *cursor,
874 struct callchain_cursor *cursor, in append_chain_children() argument
882 node = callchain_cursor_current(cursor); in append_chain_children()
894 ret = append_chain(rnode, cursor, period); in append_chain_children()
906 rnode = add_child(root, cursor, period); in append_chain_children()
921 struct callchain_cursor *cursor, in append_chain() argument
925 u64 start = cursor->pos; in append_chain()
939 node = callchain_cursor_current(cursor); in append_chain()
949 callchain_cursor_advance(cursor); in append_chain()
958 matches = cursor->pos - start; in append_chain()
962 if (split_add_child(root, cursor, cnode, start, matches, in append_chain()
970 if (matches == root->val_nr && cursor->pos == cursor->nr) { in append_chain()
977 if (append_chain_children(root, cursor, period) < 0) in append_chain()
984 struct callchain_cursor *cursor, in callchain_append() argument
987 if (!cursor->nr) in callchain_append()
990 callchain_cursor_commit(cursor); in callchain_append()
992 if (append_chain_children(&root->node, cursor, period) < 0) in callchain_append()
995 if (cursor->nr > root->max_depth) in callchain_append()
996 root->max_depth = cursor->nr; in callchain_append()
1002 merge_chain_branch(struct callchain_cursor *cursor, in merge_chain_branch() argument
1005 struct callchain_cursor_node **old_last = cursor->last; in merge_chain_branch()
1009 int old_pos = cursor->nr; in merge_chain_branch()
1013 callchain_cursor_append(cursor, list->ip, &list->ms, in merge_chain_branch()
1021 callchain_cursor_commit(cursor); in merge_chain_branch()
1022 if (append_chain_children(dst, cursor, src->hit) < 0) in merge_chain_branch()
1032 err = merge_chain_branch(cursor, dst, child); in merge_chain_branch()
1039 cursor->nr = old_pos; in merge_chain_branch()
1040 cursor->last = old_last; in merge_chain_branch()
1045 int callchain_merge(struct callchain_cursor *cursor, in callchain_merge() argument
1048 return merge_chain_branch(cursor, &dst->node, &src->node); in callchain_merge()
1051 int callchain_cursor_append(struct callchain_cursor *cursor, in callchain_cursor_append() argument
1057 struct callchain_cursor_node *node = *cursor->last; in callchain_cursor_append()
1064 *cursor->last = node; in callchain_cursor_append()
1081 cursor->nr++; in callchain_cursor_append()
1083 cursor->last = &node->next; in callchain_cursor_append()
1089 struct callchain_cursor *cursor, struct symbol **parent, in sample__resolve_callchain() argument
1098 return thread__resolve_callchain(al->thread, cursor, evsel, sample, in sample__resolve_callchain()
1590 void callchain_cursor_reset(struct callchain_cursor *cursor) in callchain_cursor_reset() argument
1594 cursor->nr = 0; in callchain_cursor_reset()
1595 cursor->last = &cursor->first; in callchain_cursor_reset()
1597 for (node = cursor->first; node != NULL; node = node->next) in callchain_cursor_reset()