~ [ source navigation ] ~ [ diff markup ] ~ [ identifier search ] ~

TOMOYO Linux Cross Reference
Linux/tools/perf/Documentation/perf.data-directory-format.txt

Version: ~ [ linux-6.12-rc7 ] ~ [ linux-6.11.7 ] ~ [ linux-6.10.14 ] ~ [ linux-6.9.12 ] ~ [ linux-6.8.12 ] ~ [ linux-6.7.12 ] ~ [ linux-6.6.60 ] ~ [ linux-6.5.13 ] ~ [ linux-6.4.16 ] ~ [ linux-6.3.13 ] ~ [ linux-6.2.16 ] ~ [ linux-6.1.116 ] ~ [ linux-6.0.19 ] ~ [ linux-5.19.17 ] ~ [ linux-5.18.19 ] ~ [ linux-5.17.15 ] ~ [ linux-5.16.20 ] ~ [ linux-5.15.171 ] ~ [ linux-5.14.21 ] ~ [ linux-5.13.19 ] ~ [ linux-5.12.19 ] ~ [ linux-5.11.22 ] ~ [ linux-5.10.229 ] ~ [ linux-5.9.16 ] ~ [ linux-5.8.18 ] ~ [ linux-5.7.19 ] ~ [ linux-5.6.19 ] ~ [ linux-5.5.19 ] ~ [ linux-5.4.285 ] ~ [ linux-5.3.18 ] ~ [ linux-5.2.21 ] ~ [ linux-5.1.21 ] ~ [ linux-5.0.21 ] ~ [ linux-4.20.17 ] ~ [ linux-4.19.323 ] ~ [ linux-4.18.20 ] ~ [ linux-4.17.19 ] ~ [ linux-4.16.18 ] ~ [ linux-4.15.18 ] ~ [ linux-4.14.336 ] ~ [ linux-4.13.16 ] ~ [ linux-4.12.14 ] ~ [ linux-4.11.12 ] ~ [ linux-4.10.17 ] ~ [ linux-4.9.337 ] ~ [ linux-4.4.302 ] ~ [ linux-3.10.108 ] ~ [ linux-2.6.32.71 ] ~ [ linux-2.6.0 ] ~ [ linux-2.4.37.11 ] ~ [ unix-v6-master ] ~ [ ccs-tools-1.8.12 ] ~ [ policy-sample ] ~
Architecture: ~ [ i386 ] ~ [ alpha ] ~ [ m68k ] ~ [ mips ] ~ [ ppc ] ~ [ sparc ] ~ [ sparc64 ] ~

  1 perf.data directory format
  2 
  3 DISCLAIMER This is not ABI yet and is subject to possible change
  4            in following versions of perf. We will remove this
  5            disclaimer once the directory format soaks in.
  6 
  7 
  8 This document describes the on-disk perf.data directory format.
  9 
 10 The layout is described by HEADER_DIR_FORMAT feature.
 11 Currently it holds only version number (0):
 12 
 13   HEADER_DIR_FORMAT = 24
 14 
 15   struct {
 16      uint64_t version;
 17   }
 18 
 19 The current only version value 0 means that:
 20   - there is a single perf.data file named 'data' within the directory.
 21   e.g.
 22 
 23     $ tree -ps perf.data
 24     perf.data
 25     └── [-rw-------       25912]  data
 26 
 27 Future versions are expected to describe different data files
 28 layout according to special needs.
 29 
 30 Currently the only 'perf record' option to output to a directory is
 31 the --kcore option which puts a copy of /proc/kcore into the directory.
 32 e.g.
 33 
 34   $ sudo perf record --kcore uname
 35   Linux
 36   [ perf record: Woken up 1 times to write data ]
 37   [ perf record: Captured and wrote 0.015 MB perf.data (9 samples) ]
 38   $ sudo tree -ps perf.data
 39   perf.data
 40   ├── [-rw-------       23744]  data
 41   └── [drwx------        4096]  kcore_dir
 42       ├── [-r--------     6731125]  kallsyms
 43       ├── [-r--------    40230912]  kcore
 44       └── [-r--------        5419]  modules
 45 
 46   1 directory, 4 files
 47   $ sudo perf script -v
 48   build id event received for vmlinux: 1eaa285996affce2d74d8e66dcea09a80c9941de
 49   build id event received for [vdso]: 8bbaf5dc62a9b644b4d4e4539737e104e4a84541
 50   build id event received for /lib/x86_64-linux-gnu/libc-2.28.so: 5b157f49586a3ca84d55837f97ff466767dd3445
 51   Samples for 'cycles' event do not have CPU attribute set. Skipping 'cpu' field.
 52   Using CPUID GenuineIntel-6-8E-A
 53   Using perf.data/kcore_dir/kcore for kernel data
 54   Using perf.data/kcore_dir/kallsyms for symbols
 55               perf 15316 2060795.480902:          1 cycles:  ffffffffa2caa548 native_write_msr+0x8 (vmlinux)
 56               perf 15316 2060795.480906:          1 cycles:  ffffffffa2caa548 native_write_msr+0x8 (vmlinux)
 57               perf 15316 2060795.480908:          7 cycles:  ffffffffa2caa548 native_write_msr+0x8 (vmlinux)
 58               perf 15316 2060795.480910:        119 cycles:  ffffffffa2caa54a native_write_msr+0xa (vmlinux)
 59               perf 15316 2060795.480912:       2109 cycles:  ffffffffa2c9b7b0 native_apic_msr_write+0x0 (vmlinux)
 60               perf 15316 2060795.480914:      37606 cycles:  ffffffffa2f121fe perf_event_addr_filters_exec+0x2e (vmlinux)
 61              uname 15316 2060795.480924:     588287 cycles:  ffffffffa303a56d page_counter_try_charge+0x6d (vmlinux)
 62              uname 15316 2060795.481067:    2261945 cycles:  ffffffffa301438f kmem_cache_free+0x4f (vmlinux)
 63              uname 15316 2060795.481643:    2172167 cycles:      7f1a48c393c0 _IO_un_link+0x0 (/lib/x86_64-linux-gnu/libc-2.28.so)

~ [ source navigation ] ~ [ diff markup ] ~ [ identifier search ] ~

kernel.org | git.kernel.org | LWN.net | Project Home | SVN repository | Mail admin

Linux® is a registered trademark of Linus Torvalds in the United States and other countries.
TOMOYO® is a registered trademark of NTT DATA CORPORATION.

sflogo.php