From: tip-bot for Adrian Hunter <tipbot@zytor.com>
To: linux-tip-commits@vger.kernel.org
Cc: tglx@linutronix.de, adrian.hunter@intel.com, acme@redhat.com,
linux-kernel@vger.kernel.org, mingo@kernel.org, hpa@zytor.com
Subject: [tip:perf/urgent] perf intel-pt: Add MTC and CYC timestamps to debug log
Date: Tue, 6 Nov 2018 11:18:00 -0800 [thread overview]
Message-ID: <tip-f6c23e3b55cb93f32a724f41af8d38888bc2ab6b@git.kernel.org> (raw)
In-Reply-To: <20181105073505.8129-3-adrian.hunter@intel.com>
Commit-ID: f6c23e3b55cb93f32a724f41af8d38888bc2ab6b
Gitweb: https://git.kernel.org/tip/f6c23e3b55cb93f32a724f41af8d38888bc2ab6b
Author: Adrian Hunter <adrian.hunter@intel.com>
AuthorDate: Mon, 5 Nov 2018 09:35:05 +0200
Committer: Arnaldo Carvalho de Melo <acme@redhat.com>
CommitDate: Mon, 5 Nov 2018 14:53:54 -0300
perf intel-pt: Add MTC and CYC timestamps to debug log
One cause of decoding errors is un-synchronized side-band data.
Timestamps are needed to debug such cases. TSC packet timestamps are
logged. Log also MTC and CYC timestamps.
Signed-off-by: Adrian Hunter <adrian.hunter@intel.com>
Link: http://lkml.kernel.org/r/20181105073505.8129-3-adrian.hunter@intel.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
tools/perf/util/intel-pt-decoder/intel-pt-decoder.c | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/tools/perf/util/intel-pt-decoder/intel-pt-decoder.c b/tools/perf/util/intel-pt-decoder/intel-pt-decoder.c
index 58f6a9ceb590..4503f3ca45ab 100644
--- a/tools/perf/util/intel-pt-decoder/intel-pt-decoder.c
+++ b/tools/perf/util/intel-pt-decoder/intel-pt-decoder.c
@@ -1474,6 +1474,8 @@ static void intel_pt_calc_mtc_timestamp(struct intel_pt_decoder *decoder)
decoder->have_calc_cyc_to_tsc = false;
intel_pt_calc_cyc_to_tsc(decoder, true);
}
+
+ intel_pt_log_to("Setting timestamp", decoder->timestamp);
}
static void intel_pt_calc_cbr(struct intel_pt_decoder *decoder)
@@ -1514,6 +1516,8 @@ static void intel_pt_calc_cyc_timestamp(struct intel_pt_decoder *decoder)
decoder->timestamp = timestamp;
decoder->timestamp_insn_cnt = 0;
+
+ intel_pt_log_to("Setting timestamp", decoder->timestamp);
}
/* Walk PSB+ packets when already in sync. */
next prev parent reply other threads:[~2018-11-06 19:18 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-11-05 7:35 [PATCH 0/2] perf intel-pt: Add more information to debug log Adrian Hunter
2018-11-05 7:35 ` [PATCH 1/2] perf intel-pt: Add more event " Adrian Hunter
2018-11-06 19:17 ` [tip:perf/urgent] " tip-bot for Adrian Hunter
2018-11-05 7:35 ` [PATCH 2/2] perf intel-pt: Add MTC and CYC timestamps " Adrian Hunter
2018-11-06 19:18 ` tip-bot for Adrian Hunter [this message]
2018-11-05 17:54 ` [PATCH 0/2] perf intel-pt: Add more information " Arnaldo Carvalho de Melo
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=tip-f6c23e3b55cb93f32a724f41af8d38888bc2ab6b@git.kernel.org \
--to=tipbot@zytor.com \
--cc=acme@redhat.com \
--cc=adrian.hunter@intel.com \
--cc=hpa@zytor.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-tip-commits@vger.kernel.org \
--cc=mingo@kernel.org \
--cc=tglx@linutronix.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).