On 03/09/15 14:23, Jan Stancek wrote:
> objdump output can contain repeated bytes. At the moment test reads
> all output sequentially, assuming each address is represented in
> output only once:
> 
>   ffffffff8164efb3 <retint_swapgs+0x9>:
>   ffffffff8164efb3:  c1 5d 00 eb        rcrl   $0xeb,0x0(%rbp)
>   ffffffff8164efb7:  00 4c 8b 5c        add    %cl,0x5c(%rbx,%rcx,4)
> 
>   ffffffff8164efb8 <restore_c_regs_and_iret>:
>   ffffffff8164efb8:  4c 8b 5c 24 30     mov    0x30(%rsp),%r11
>   ffffffff8164efbd:  4c 8b 54 24 38     mov    0x38(%rsp),%r10
> 
> Store objdump output to buffer according to offset calculated
> from address on each line.
> 
> Signed-off-by: Jan Stancek <[email protected]>
> Cc: Arnaldo Carvalho de Melo <[email protected]>
> Cc: Jiri Olsa <[email protected]>
> Cc: Adrian Hunter <[email protected]>
> Cc: David Ahern <[email protected]>
> Cc: Corey Ashford <[email protected]>
> Cc: Frederic Weisbecker <[email protected]>
> Cc: Ingo Molnar <[email protected]>
> Cc: Namhyung Kim <[email protected]>
> Cc: Paul Mackerras <[email protected]>
> Cc: Peter Zijlstra <[email protected]>
> ---
>  tools/perf/tests/code-reading.c | 53 
> +++++++++++++++++++++++++++++++----------
>  1 file changed, 40 insertions(+), 13 deletions(-)
> 
> Changes in v3:
>   align read_objdump_line parameters on 2nd line
>   fix multiline comment
>   replace MIN with min
> 

Acked-by: Adrian Hunter <[email protected]>

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Reply via email to