Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1231657

RE: [PATCH RFC 06/10] perf,tools: option to set counter read interval

From "Liang, Kan" <kan.liang@intel.com>
Newsgroups linux.kernel
Subject RE: [PATCH RFC 06/10] perf,tools: option to set counter read interval
Date 2015-09-23 21:10 +0200
Message-ID <qbXAt-4LB-1@gated-at.bofh.it> (permalink)
References <qbDs5-IB-3@gated-at.bofh.it> <qbDs5-IB-15@gated-at.bofh.it> <qbXqO-4lb-7@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


> 
> kan.liang@intel.com [kan.liang@intel.com] wrote:
> | From: Kan Liang <kan.liang@intel.com>
> |
> | Add a timer to read counter regularly. Option --counter-read-interval
> | can be used to set the interval.
> | Only read counter statistics at the beginning and the end is not enough.
> | Sometimes, we need fine granularity to do sophisticated analysis. For
> | example,10-20ms is required to do sophisticated bandwidth analysis.
> |
> | Signed-off-by: Kan Liang <kan.liang@intel.com>
> | ---
> |  tools/perf/Documentation/perf-record.txt |  8 +++++++
> |  tools/perf/builtin-record.c              | 37
> ++++++++++++++++++++++++++++++++
> |  2 files changed, 45 insertions(+)
> |
> | diff --git a/tools/perf/Documentation/perf-record.txt
> | b/tools/perf/Documentation/perf-record.txt
> | index 2e9ce77..c1d9024 100644
> | --- a/tools/perf/Documentation/perf-record.txt
> | +++ b/tools/perf/Documentation/perf-record.txt
> | @@ -308,6 +308,14 @@ This option sets the time out limit. The default
> value is 500 ms.
> |  Record context switch events i.e. events of type PERF_RECORD_SWITCH
> | or  PERF_RECORD_SWITCH_CPU_WIDE.
> |
> | +--counter-read-interval::
> | +Sets the interval to do counter read regularly. This option is only
> | +valid
> 
> How about "Sets the interval at which the counter should be read"?
> 
> | +with counter read event (:C). This option is disabled by default. It
> | +means that the event counter can only be read at the beginning and the
> end.
> 
> Should this last sentence be: "When this option is disabled, the event
> counter can only be read at the beginning and the end?"
> 
> | +This option could be used when we need fine granularity to do
> | +sophisticated analysis. For example, 10-20ms is required to do
> | +sophisticated memory bandwidth analysis.
> 
> I guess this is independent of the sampling frequency (perf-record -F)?
> 
> IOW, is the need for --counter-read-interval so we can sample at one
> frequency, but read the counter values/statistics at a different frequency?

Right, --counter-read-interval is independent of sampling freq.
If we set --counter-read-interval to 10ms, it will read counter every 10ms
no matter what sampling frequency is set.

Thanks,
Kan
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Back to linux.kernel | Previous | NextPrevious in thread | Find similar | Unroll thread


Thread

[PATCH RFC 06/10] perf,tools: option to set counter read interval kan.liang@intel.com - 2015-09-22 23:40 +0200
  Re: [PATCH RFC 06/10] perf,tools: option to set counter read interval Sukadev Bhattiprolu <sukadev@linux.vnet.ibm.com> - 2015-09-23 21:00 +0200
    RE: [PATCH RFC 06/10] perf,tools: option to set counter read  interval "Liang, Kan" <kan.liang@intel.com> - 2015-09-23 21:10 +0200

csiph-web