Patch "perf annotate: Do not truncate instruction names at 6 chars" has been added to the 4.14-stable tree
Subsystems (2)
This is a note to let you know that I've just added the patch titled
perf annotate: Do not truncate instruction names at 6 chars
to the 4.14-stable tree which can be found at:
http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary
The filename of the patch is:
perf-annotate-do-not-truncate-instruction-names-at-6-chars.patch
and it can be found in the queue-4.14 subdirectory.
If you, or anyone else, feels it should not be added to the stable tree, please let <[email protected]> know about it.
Quoted 1 line
From foo@baz Fri Feb 23 11:45:09 CET 2018
From: Ravi Bangoria <[email protected]>
Date: Tue, 14 Nov 2017 08:55:40 +0530
Subject: perf annotate: Do not truncate instruction names at 6 chars
From: Ravi Bangoria <[email protected]>
[ Upstream commit 05d0e62d9fa0f1002cf82009ef31b36174da5472 ]
There are many instructions, esp on PowerPC, whose mnemonics are longer than 6 characters. Using precision limit causes truncation of such mnemonics.
Fix this by removing precision limit. Note that, 'width' is still 6, so alignment won't get affected for length <= 6.
Before:
li r11,-1
xscvdp vs1,vs1
add. r10,r10,r11
After:
li r11,-1
xscvdpsxds vs1,vs1
add. r10,r10,r11
--- tools/perf/util/annotate.c | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-)
tools/perf/util/annotate.c +9 -9
@@ -166,7 +166,7 @@ static void ins__delete(struct ins_operastatic int ins__raw_scnprintf (struct ins *ins,char *bf,size_t size,struct ins_operands *ops) { -return scnprintf (bf, size,"%-6.6s %s" , ins->name, ops->raw); +return scnprintf (bf, size,"%-6s %s" , ins->name, ops->raw); } int ins__scnprintf(struct ins *ins, char *bf, size_t size,
@@ -231,12 +231,12 @@ static int call__scnprintf(struct ins *i struct ins_operands *ops) {if (ops->target.name) -return scnprintf (bf, size,"%-6.6s %s" , ins->name, ops->target.name); +return scnprintf (bf, size,"%-6s %s" , ins->name, ops->target.name);if (ops->target.addr ==0 )return ins__raw_scnprintf (ins, bf, size, ops); -return scnprintf (bf, size,"%-6.6s *%" PRIx64, ins->name, ops->target.addr); +return scnprintf (bf, size,"%-6s *%" PRIx64, ins->name, ops->target.addr); }static struct ins_ops call_ops = {
@@ -300,7 +300,7 @@ static int jump__scnprintf(struct ins *i c++; } -return scnprintf (bf, size,"%-6.6s %.*s%" PRIx64, +return scnprintf (bf, size,"%-6s %.*s%" PRIx64, ins->name, c ? c - ops->raw :0 , ops->raw, ops->target.offset); }
@@ -373,7 +373,7 @@ static int lock__scnprintf(struct ins *iif (ops->locked.ins.ops ==NULL )return ins__raw_scnprintf (ins, bf, size, ops); - printed =scnprintf (bf, size,"%-6.6s " , ins->name); + printed =scnprintf (bf, size,"%-6s " , ins->name);return printed +ins__scnprintf (&ops->locked.ins, bf + printed, size - printed, ops->locked.ops); }
@@ -449,7 +449,7 @@ out_free_source:static int mov__scnprintf (struct ins *ins,char *bf,size_t size,struct ins_operands *ops) { -return scnprintf (bf, size,"%-6.6s %s,%s" , ins->name, +return scnprintf (bf, size,"%-6s %s,%s" , ins->name, ops->source.name ?: ops->source.raw, ops->target.name ?: ops->target.raw); }
@@ -489,7 +489,7 @@ static int dec__parse(struct arch *archstatic int dec__scnprintf (struct ins *ins,char *bf,size_t size,struct ins_operands *ops) { -return scnprintf (bf, size,"%-6.6s %s" , ins->name, +return scnprintf (bf, size,"%-6s %s" , ins->name, ops->target.name ?: ops->target.raw); }
@@ -501,7 +501,7 @@ static struct ins_ops dec_ops = {static int nop__scnprintf (struct ins *ins__maybe_unused ,char *bf,size_t size,struct ins_operands *ops__maybe_unused ) { -return scnprintf (bf, size,"%-6.6s" ,"nop" ); +return scnprintf (bf, size,"%-6s" ,"nop" ); }static struct ins_ops nop_ops = {
@@ -925,7 +925,7 @@ void disasm_line__free(struct disasm_linint disasm_line__scnprintf (struct disasm_line *dl,char *bf,size_t size,bool raw) {if (raw || !dl->ins.ops) -return scnprintf (bf, size,"%-6.6s %s" , dl->ins.name, dl->ops.raw); +return scnprintf (bf, size,"%-6s %s" , dl->ins.name, dl->ops.raw);return ins__scnprintf (&dl->ins, bf, size, &dl->ops); }
Patches currently in stable-queue which might be from [email protected] are
queue-4.14/perf-top-fix-window-dimensions-change-handling.patch queue-4.14/perf-annotate-do-not-truncate-instruction-names-at-6-chars.patch queue-4.14/powerpc-perf-fix-oops-when-grouping-different-pmu-events.patch