perf tools: Show progress on histogram collapsing
It can take quite amount of time so add progress bar UI to inform user. Signed-off-by: Namhyung Kim <namhyung@kernel.org> Cc: Frederic Weisbecker <fweisbec@gmail.com> Cc: Ingo Molnar <mingo@kernel.org> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Paul Mackerras <paulus@samba.org> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> Link: http://lkml.kernel.org/r/1381468543-25334-4-git-send-email-namhyung@kernel.org [ perf_progress -> ui_progress ] Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
This commit is contained in:
parent
4d3001fdfd
commit
c1fb5651bb
7 changed files with 20 additions and 8 deletions
|
@ -399,6 +399,7 @@ static struct hist_entry *add_hist_entry(struct hists *hists,
|
|||
if (!he)
|
||||
return NULL;
|
||||
|
||||
hists->nr_entries++;
|
||||
rb_link_node(&he->rb_node_in, parent, p);
|
||||
rb_insert_color(&he->rb_node_in, hists->entries_in);
|
||||
out:
|
||||
|
@ -604,7 +605,7 @@ static void hists__apply_filters(struct hists *hists, struct hist_entry *he)
|
|||
hists__filter_entry_by_symbol(hists, he);
|
||||
}
|
||||
|
||||
void hists__collapse_resort(struct hists *hists)
|
||||
void hists__collapse_resort(struct hists *hists, struct ui_progress *prog)
|
||||
{
|
||||
struct rb_root *root;
|
||||
struct rb_node *next;
|
||||
|
@ -631,6 +632,8 @@ void hists__collapse_resort(struct hists *hists)
|
|||
*/
|
||||
hists__apply_filters(hists, n);
|
||||
}
|
||||
if (prog)
|
||||
ui_progress__update(prog, 1);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue