]> git.baikalelectronics.ru Git - kernel.git/commit
perf intel-pt: Fix last_ip usage
authorAdrian Hunter <adrian.hunter@intel.com>
Fri, 26 May 2017 08:17:06 +0000 (11:17 +0300)
committerArnaldo Carvalho de Melo <acme@redhat.com>
Wed, 21 Jun 2017 14:35:45 +0000 (11:35 -0300)
commit1df5bfac078d4a664ed57201f23caa40f3d9df84
tree3b6fecdc06348f419eea3f58672d22b7ae0c82d7
parent652ce050dbab50be87acfe6103a699dcac7031e4
perf intel-pt: Fix last_ip usage

Intel PT uses IP compression based on the last IP. For decoding
purposes, 'last IP' is considered to be reset to zero whenever there is
a synchronization packet (PSB). The decoder wasn't doing that, and was
treating the zero value to mean that there was no last IP, whereas
compression can be done against the zero value. Fix by setting last_ip
to zero when a PSB is received and keep track of have_last_ip.

Signed-off-by: Adrian Hunter <adrian.hunter@intel.com>
Cc: Andi Kleen <ak@linux.intel.com>
Cc: stable@vger.kernel.org
Link: http://lkml.kernel.org/r/1495786658-18063-6-git-send-email-adrian.hunter@intel.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
tools/perf/util/intel-pt-decoder/intel-pt-decoder.c