linux/include
Kan Liang bbfd5e4fab perf/core: Add new branch sample type for HW index of raw branch records
The low level index is the index in the underlying hardware buffer of
the most recently captured taken branch which is always saved in
branch_entries[0]. It is very useful for reconstructing the call stack.
For example, in Intel LBR call stack mode, the depth of reconstructed
LBR call stack limits to the number of LBR registers. With the low level
index information, perf tool may stitch the stacks of two samples. The
reconstructed LBR call stack can break the HW limitation.

Add a new branch sample type to retrieve low level index of raw branch
records. The low level index is between -1 (unknown) and max depth which
can be retrieved in /sys/devices/cpu/caps/branches.

Only when the new branch sample type is set, the low level index
information is dumped into the PERF_SAMPLE_BRANCH_STACK output.
Perf tool should check the attr.branch_sample_type, and apply the
corresponding format for PERF_SAMPLE_BRANCH_STACK samples.
Otherwise, some user case may be broken. For example, users may parse a
perf.data, which include the new branch sample type, with an old version
perf tool (without the check). Users probably get incorrect information
without any warning.

Signed-off-by: Kan Liang <kan.liang@linux.intel.com>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Link: https://lkml.kernel.org/r/20200127165355.27495-2-kan.liang@linux.intel.com
2020-02-11 13:23:49 +01:00
..
acpi
asm-generic Microblaze patches for 5.6-rc1 2020-02-04 11:58:07 +00:00
clocksource
crypto
drm
dt-bindings ARM: SoC: late updates 2020-02-08 14:17:27 -08:00
keys
kunit
kvm
linux perf/core: Add new branch sample type for HW index of raw branch records 2020-02-11 13:23:49 +01:00
math-emu
media
misc
net bonding/alb: properly access headers in bond_alb_xmit() 2020-02-05 14:28:09 +01:00
pcmcia
ras
rdma RDMA/core: Make the entire API tree static 2020-01-30 16:28:52 -04:00
scsi
soc ARM: SoC-related driver updates 2020-02-08 14:04:19 -08:00
sound ARM: Device-tree updates 2020-02-08 13:58:44 -08:00
target
trace ARM: SoC-related driver updates 2020-02-08 14:04:19 -08:00
uapi perf/core: Add new branch sample type for HW index of raw branch records 2020-02-11 13:23:49 +01:00
vdso
video
xen xen: branch for v5.6-rc1 2020-02-05 17:44:14 +00:00