Em Wed, Aug 21, 2013 at 12:10:25PM +0200, Stephane Eranian escreveu: > This patch adds support for the new PERF_RECORD_MMAP2 > record type exposed by the kernel. This is an extended > PERF_RECORD_MMAP record. It adds for each file-backed > mapping the device major, minor number and the inode > number and generation. This triplet uniquely identifies > the source of a file-backed mapping. It can be used to > detect identical virtual mappings between processes, for > instance. > > The patch will prefer MMAP2 over MMAP.
I noticed the kernel part is in, and I'm going to use MMAP2 on that new tool, so tried merging it, but: I fixed it up wrt another patch that makes machine__find_thread receive pid/tid but then 'perf test' complains about it, see below, trying to fix... - Arnaldo [root@sandy ~]# perf test -v 7 7: Validate PERF_RECORD_* events & perf_sample fields : --- start --- 57503587100282 0 PERF_RECORD_SAMPLE 57503587104415 0 PERF_RECORD_SAMPLE 57503587106039 0 PERF_RECORD_SAMPLE 57503587107362 0 PERF_RECORD_SAMPLE 57503588263263 0 PERF_RECORD_COMM: sleep:1439 6180457940383 -1728826693 PERF_RECORD_MMAP2 1439/1439: [0x400000(0x7000) @ 0 00:1d 311442 9016]: /usr/bin/sleep MMAP2 going backwards in time, prev=57503588263263, curr=6180457940383 MMAP2 with unexpected cpu, expected 0, got -1728826693 MMAP2 with unexpected pid, expected 1439, got 1701606191 MMAP2 with unexpected tid, expected 1439, got 28773 Unexpected perf_event->header.type 10! 6180457940383 -1728754371 PERF_RECORD_MMAP2 1439/1439: [0x3b7e000000(0x223000) @ 0 00:1d 309186 9016]: /usr/lib64/ld-2.16.so MMAP2 with unexpected cpu, expected 0, got -1728754371 MMAP2 with unexpected pid, expected 1439, got 1932408369 MMAP2 with unexpected tid, expected 1439, got 111 Unexpected perf_event->header.type 10! 6180457940383 -1728699354 PERF_RECORD_MMAP2 1439/1439: [0x7fff2bdff000(0x1000) @ 0x7fff2bdff000 00:00 0 0]: [vdso] MMAP2 with unexpected cpu, expected 0, got -1728699354 MMAP2 with unexpected pid, expected 1439, got 1935963739 MMAP2 with unexpected tid, expected 1439, got 23919 Unexpected perf_event->header.type 10! 6180457940383 -1728433298 PERF_RECORD_MMAP2 1439/1439: [0x3b7e400000(0x3b8000) @ 0 00:1d 309187 9016]: /usr/lib64/libc-2.16.so MMAP2 with unexpected cpu, expected 0, got -1728433298 MMAP2 with unexpected pid, expected 1439, got 909192754 MMAP2 with unexpected tid, expected 1439, got 7303982 Unexpected perf_event->header.type 10! 57504589856948 0 PERF_RECORD_EXIT(1439:1439):(1439:1439) PERF_RECORD_MMAP for sleep missing! PERF_RECORD_MMAP for libc missing! PERF_RECORD_MMAP for ld missing! PERF_RECORD_MMAP for [vdso] missing! ---- end ---- Validate PERF_RECORD_* events & perf_sample fields: FAILED! [root@sandy ~]# -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/