linux-stable/tools/perf/util/intel-pt-decoder
Adrian Hunter 80a038860b perf intel-pt: Amend decoder to track the NR flag
The PIP packet NR (non-root) flag indicates whether or not a virtual
machine is being traced (NR=1 => VM). Add support for tracking its value.

In particular note that the PIP packet (outside of PSB+) will be
associated with a TIP packet from which address the NR value takes
effect. At that point, there is a branch from_ip, to_ip with
corresponding from_nr and to_nr.

In the event of VM-Entry failure, there should still PIP and TIP packets
that can be followed in the same way.

Also note that this assumes that a host VMM is not employing VMX controls
that affect Intel PT, e.g. to hide the host from a guest using Intel PT.

Signed-off-by: Adrian Hunter <adrian.hunter@intel.com>
Acked-by: Andi Kleen <ak@linux.intel.com>
Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com>
Cc: Jiri Olsa <jolsa@redhat.com>
Link: https://lore.kernel.org/r/20210218095801.19576-5-adrian.hunter@intel.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
2021-02-18 16:13:56 -03:00
..
Build perf intel-pt: Use shared x86 insn decoder 2019-08-31 22:27:52 -03:00
intel-pt-decoder.c perf intel-pt: Amend decoder to track the NR flag 2021-02-18 16:13:56 -03:00
intel-pt-decoder.h perf intel-pt: Amend decoder to track the NR flag 2021-02-18 16:13:56 -03:00
intel-pt-insn-decoder.c perf intel_pt: Add vmlaunch and vmresume as branches 2021-02-18 16:13:30 -03:00
intel-pt-insn-decoder.h perf intel_pt: Add vmlaunch and vmresume as branches 2021-02-18 16:13:30 -03:00
intel-pt-log.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 288 2019-06-05 17:36:37 +02:00
intel-pt-log.h treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 288 2019-06-05 17:36:37 +02:00
intel-pt-pkt-decoder.c perf intel-pt: Retain the last PIP packet payload as is 2021-02-18 16:13:46 -03:00
intel-pt-pkt-decoder.h perf intel-pt: Retain the last PIP packet payload as is 2021-02-18 16:13:46 -03:00