All of lore.kernel.org
 help / color / mirror / Atom feed
From: Arnaldo Carvalho de Melo <acme@kernel.org>
To: ufo19890607 <ufo19890607@gmail.com>
Cc: peterz@infradead.org, mingo@redhat.com,
	alexander.shishkin@linux.intel.com, jolsa@kernel.org,
	dsahern@gmail.com, namhyung@kernel.org, milian.wolff@kdab.com,
	arnaldo.melo@gmail.com, yuzhoujian@didichuxing.com,
	adrian.hunter@intel.com, wangnan0@huawei.com,
	Kan.liang@intel.com, linux-perf-users@vger.kernel.org,
	linux-kernel@vger.kernel.org, acme@redhat.com
Subject: Re: [PATCH v4 2/2] perf stat: Add support to print counts after a period of time
Date: Fri, 16 Feb 2018 10:18:15 -0300	[thread overview]
Message-ID: <20180216131815.GB24436@kernel.org> (raw)
In-Reply-To: <20180215133921.GC22818@kernel.org>

Em Thu, Feb 15, 2018 at 10:39:21AM -0300, Arnaldo Carvalho de Melo escreveu:
> Em Mon, Jan 29, 2018 at 10:25:23AM +0100, ufo19890607 escreveu:
> > From: yuzhoujian <yuzhoujian@didichuxing.com>
> > 
> > Introduce a new option to print counts after N milliseconds
> 
> This doesn't just print counts after N ms, it _stops_ the workload after
> that time _and_ prints the counts, right?
> 
> Can you please send a followup patch fixing the description and
> documentation?
> 
> I've applied this already, but clarifying what this option does is in
> demand.

So, this fails to build on centos:5 and centos:6 and similar systems
where the use of 'time' for a variable name breaks the build:

  CC       /tmp/build/perf/builtin-stat.o
cc1: warnings being treated as errors
builtin-stat.c: In function '__run_perf_stat':
builtin-stat.c:576: warning: declaration of 'time' shadows a global declaration
/usr/include/time.h:187: warning: shadowed declaration is here
builtin-stat.c: In function 'cmd_stat':
builtin-stat.c:2710: warning: declaration of 'time' shadows a global declaration
/usr/include/time.h:187: warning: shadowed declaration is here
mv: cannot stat `/tmp/build/perf/.builtin-stat.o.tmp': No such file or directory
make[3]: *** [/tmp/build/perf/builtin-stat.o] Error 1
make[3]: *** Waiting for unfinished jobs....
  MKDIR    /tmp/build/perf/util/
  CC       /tmp/build/perf/util/evsel_fprintf.o
make[2]: *** [/tmp/build/perf/perf-in.o] Error 2
make[2]: *** Waiting for unfinished jobs....

So since I had to rename that I replaced it with 'timeout', so that it
gets clear that when you specify this option you are setting a timeout
period that if hit will stop the 'perf stat' session and then print the
specified counters.

Please let us know if you have any strong objection to this,

- Arnaldo

  reply	other threads:[~2018-02-16 13:18 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-01-29  9:25 [PATCH v4 0/2] perf stat: Add interval-count and time support ufo19890607
2018-01-29  9:25 ` [PATCH v4 1/2] perf stat: Add support to print counts for fixed times ufo19890607
2018-02-17 11:23   ` [tip:perf/core] " tip-bot for yuzhoujian
2018-01-29  9:25 ` [PATCH v4 2/2] perf stat: Add support to print counts after a period of time ufo19890607
2018-02-15 13:39   ` Arnaldo Carvalho de Melo
2018-02-16 13:18     ` Arnaldo Carvalho de Melo [this message]
2018-02-17 11:23   ` [tip:perf/core] " tip-bot for yuzhoujian
2018-01-29 10:25 ` [PATCH v4 0/2] perf stat: Add interval-count and time support Jiri Olsa
     [not found]   ` <CAHCio2iVBoEXEv3mXzq34FsDZXJT9Oig+SfDwv3vneYfZQ089g@mail.gmail.com>
2018-02-15 10:44     ` Jiri Olsa

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=20180216131815.GB24436@kernel.org \
    --to=acme@kernel.org \
    --cc=Kan.liang@intel.com \
    --cc=acme@redhat.com \
    --cc=adrian.hunter@intel.com \
    --cc=alexander.shishkin@linux.intel.com \
    --cc=arnaldo.melo@gmail.com \
    --cc=dsahern@gmail.com \
    --cc=jolsa@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-perf-users@vger.kernel.org \
    --cc=milian.wolff@kdab.com \
    --cc=mingo@redhat.com \
    --cc=namhyung@kernel.org \
    --cc=peterz@infradead.org \
    --cc=ufo19890607@gmail.com \
    --cc=wangnan0@huawei.com \
    --cc=yuzhoujian@didichuxing.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.