diff options
author | Arnaldo Carvalho de Melo <acme@redhat.com> | 2021-05-25 14:13:52 +0200 |
---|---|---|
committer | Arnaldo Carvalho de Melo <acme@redhat.com> | 2021-05-25 14:13:52 +0200 |
commit | 100475f83b9d2fbdb6f34a9b5fca9318e039b2d6 (patch) | |
tree | 630d9e2403541d9005ecf4a9aca52ca0befab217 /tools/perf/util/intel-pt.c | |
parent | perf tests: Drop __maybe_unused on x86 test declarations (diff) | |
parent | Merge tag 'perf-tools-fixes-for-v5.13-2021-05-24' of git://git.kernel.org/pub... (diff) | |
download | linux-100475f83b9d2fbdb6f34a9b5fca9318e039b2d6.tar.xz linux-100475f83b9d2fbdb6f34a9b5fca9318e039b2d6.zip |
Merge remote-tracking branch 'torvalds/master' into perf/core
To pick up fixes from perf/urgent.
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Diffstat (limited to 'tools/perf/util/intel-pt.c')
-rw-r--r-- | tools/perf/util/intel-pt.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/tools/perf/util/intel-pt.c b/tools/perf/util/intel-pt.c index 2a5fe1514e65..154a1077f22e 100644 --- a/tools/perf/util/intel-pt.c +++ b/tools/perf/util/intel-pt.c @@ -778,8 +778,10 @@ static int intel_pt_walk_next_insn(struct intel_pt_insn *intel_pt_insn, *ip += intel_pt_insn->length; - if (to_ip && *ip == to_ip) + if (to_ip && *ip == to_ip) { + intel_pt_insn->length = 0; goto out_no_cache; + } if (*ip >= al.map->end) break; @@ -1301,6 +1303,7 @@ static void intel_pt_set_pid_tid_cpu(struct intel_pt *pt, static void intel_pt_sample_flags(struct intel_pt_queue *ptq) { + ptq->insn_len = 0; if (ptq->state->flags & INTEL_PT_ABORT_TX) { ptq->flags = PERF_IP_FLAG_BRANCH | PERF_IP_FLAG_TX_ABORT; } else if (ptq->state->flags & INTEL_PT_ASYNC) { @@ -1314,7 +1317,6 @@ static void intel_pt_sample_flags(struct intel_pt_queue *ptq) ptq->flags = PERF_IP_FLAG_BRANCH | PERF_IP_FLAG_CALL | PERF_IP_FLAG_ASYNC | PERF_IP_FLAG_INTERRUPT; - ptq->insn_len = 0; } else { if (ptq->state->from_ip) ptq->flags = intel_pt_insn_type(ptq->state->insn_op); |