perf annotate: Initialize proper width for first column
PATCH v4 2/9 perf annotate: Initialize proper width for first column
When using --show-total-period or not,
set the width value for first column.
Suggested-by Arnaldo Carvalho de Melo <[email protected]>
Cc Namhyung Kim <[email protected]>
Cc Jiri Olsa <[email protected]>
Signed-off-by Taeung Song <[email protected]>
--- tools/perf/util/annotate.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
tools/perf/util/annotate.c +2 -2
@@ -1165,7 +1165,7 @@ static int disasm_line__print(struct disasm_line *dl, struct symbol *sym, u64 st }else if (max_lines && printed >= max_lines)return 1 ;else { -int width =8 ; +int width = symbol_conf.show_total_period ?12 :8 ;if (queue)return -1 ;
@@ -1806,7 +1806,7 @@ int symbol__annotate_printf(struct symbol *sym, struct map *map,int printed =2 , queue_len =0 ;int more =0 ;u64 len; -int width =8 ; +int width = symbol_conf.show_total_period ?12 :8 ;int graph_dotted_len; filename =strdup (dso->long_name);
Signature · 1 line
2.7.4
Arnaldo Carvalho de Melo
maintainerEm Fri, Jul 28, 2017 at 01:15:56AM +0900, Taeung Song escreveu:
Quoted 25 lines
When using --show-total-period or not,
set the width value for first column.Suggested-by Arnaldo Carvalho de Melo <[email protected]>Cc Namhyung Kim <[email protected]>Cc Jiri Olsa <[email protected]>Signed-off-by Taeung Song <[email protected]>--- tools/perf/util/annotate.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)tools/perf/util/annotate.c +1
-1@@ -1165,7 +1165,7 @@ static int disasm_line__print(struct disasm_line *dl, struct symbol *sym, u64 st }else if (max_lines && printed >= max_lines)return 1 ;else { -int width =8 ; +int width = symbol_conf.show_total_period ?12 :8 ;if (queue)return -1 ;
tools/perf/util/annotate.c int symbol__annotate_printf(struct symbol *sym, struct map *map, · line 1810
Quoted 6 lines
tools/perf/util/annotate.c +1
-1@@ -1806,7 +1806,7 @@ int symbol__annotate_printf(struct symbol *sym, struct map *map,int printed =2 , queue_len =0 ;int more =0 ;u64 len; -int width =8 ; +int width = symbol_conf.show_total_period ?12 :8 ;int graph_dotted_len;
Already at:
- Arnaldo