lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Wed, 3 Oct 2012 06:47:57 -0700
From:	Arnaldo Carvalho de Melo <acme@...stprotocols.net>
To:	Andi Kleen <andi@...stfloor.org>
Cc:	Jiri Olsa <jolsa@...hat.com>, linux-kernel@...r.kernel.org,
	Peter Zijlstra <a.p.zijlstra@...llo.nl>,
	Ingo Molnar <mingo@...e.hu>, Paul Mackerras <paulus@...ba.org>,
	Corey Ashford <cjashfor@...ux.vnet.ibm.com>,
	Frederic Weisbecker <fweisbec@...il.com>,
	"Paul E. McKenney" <paulmck@...ux.vnet.ibm.com>,
	David Ahern <dsahern@...il.com>,
	Namhyung Kim <namhyung@...nel.org>
Subject: Re: [PATCHv2 00/14] perf diff: Factor diff command

Em Tue, Oct 02, 2012 at 06:30:02PM +0200, Andi Kleen escreveu:
> The other problem I ran into is that perf archive doesn't seem to work very
> well with kernels, so it's hard to move profiles from different kernels
> around to diff them (e.g. for a performance regression) One way around this
> would be options to diff to specify the vmlinux etc.  manually

Can you describe more precisely what is not working well with 'archive'
and build ids?

When you do a 'perf record', at the end of the session, it traverses the
samples looking for DSOs with hits, and then stashes a copy (or a
hardlink, if possible) of these DSOs in your ~/.cache/, keyed by its
build id.

Later, when you do a perf archive, it will look again at your perf.data
files, look again for DSOs with hits and pass them on a tar command
line, you transfer those tarballs to your analysis machine and it should
just work.

To debug you may follow some of these steps:

[root@...dy linux]# perf record -a usleep 1
[ perf record: Woken up 1 times to write data ]
[ perf record: Captured and wrote 0.447 MB perf.data (~19534 samples) ]
[root@...dy linux]# perf buildid-list 
62b97af6897371571caef35fd5ae88e29bde5e89 [kernel.kallsyms]
[root@...dy linux]# ls -la ~/.debug/.build-id/62/b97af6897371571caef35fd5ae88e29bde5e89 
lrwxrwxrwx. 1 root root 64 Oct  3 10:41 /root/.debug/.build-id/62/b97af6897371571caef35fd5ae88e29bde5e89 -> ../../[kernel.kallsyms]/62b97af6897371571caef35fd5ae88e29bde5e89
[root@...dy linux]# perf buildid-list --hell
  Error: unknown option `hell'

 usage: perf buildid-list [<options>]

    -H, --with-hits       Show only DSOs with hits
    -i, --input <file>    input file name
    -f, --force           don't complain, do it
    -k, --kernel          Show current kernel build id
    -v, --verbose         be more verbose

[root@...dy linux]# perf buildid-list -k
62b97af6897371571caef35fd5ae88e29bde5e89
[root@...dy linux]# perf archive
Now please run:

$ tar xvf perf.data.tar.bz2 -C ~/.debug

wherever you need to run 'perf report' on.
[root@...dy linux]# tar tvf perf.data.tar.bz2
lrwxrwxrwx root/root         0 2012-10-03 10:41 .build-id/62/b97af6897371571caef35fd5ae88e29bde5e89 -> ../../[kernel.kallsyms]/62b97af6897371571caef35fd5ae88e29bde5e89
-rw-r--r-- root/root   4115683 2012-10-03 10:41 [kernel.kallsyms]/62b97af6897371571caef35fd5ae88e29bde5e89
[root@...dy linux]# 

[root@...dy linux]# sha256sum /root/.debug/.build-id/62/b97af6897371571caef35fd5ae88e29bde5e89 /proc/kallsyms 
43724edebe7f144d43a8664e237fa14df96bb79943002f1f17f45379a16418bf  /root/.debug/.build-id/62/b97af6897371571caef35fd5ae88e29bde5e89
43724edebe7f144d43a8664e237fa14df96bb79943002f1f17f45379a16418bf  /proc/kallsyms
[root@...dy linux]# 

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

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ