perf tools: Save column length in perf_hpp_fmt
Save column length in the hpp format and pass it to print functions. This is a preparation for users to control column width in the output. Signed-off-by: Namhyung Kim <namhyung@kernel.org> Cc: Ingo Molnar <mingo@kernel.org> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Namhyung Kim <namhyung.kim@lge.com> Cc: Paul Mackerras <paulus@samba.org> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> Link: http://lkml.kernel.org/r/1406785662-5534-4-git-send-email-namhyung@kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
This commit is contained in:
parent
d675107ce6
commit
e0d66c74b0
4 changed files with 94 additions and 48 deletions
|
@ -1194,7 +1194,7 @@ bool perf_hpp__same_sort_entry(struct perf_hpp_fmt *a, struct perf_hpp_fmt *b)
|
|||
return hse_a->se == hse_b->se;
|
||||
}
|
||||
|
||||
void perf_hpp__reset_width(struct perf_hpp_fmt *fmt, struct hists *hists)
|
||||
void perf_hpp__reset_sort_width(struct perf_hpp_fmt *fmt, struct hists *hists)
|
||||
{
|
||||
struct hpp_sort_entry *hse;
|
||||
|
||||
|
@ -1265,6 +1265,7 @@ __sort_dimension__alloc_hpp(struct sort_dimension *sd)
|
|||
INIT_LIST_HEAD(&hse->hpp.list);
|
||||
INIT_LIST_HEAD(&hse->hpp.sort_list);
|
||||
hse->hpp.elide = false;
|
||||
hse->hpp.len = 0;
|
||||
|
||||
return hse;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue