Re: [PATCH 1/6] perf tool: Add time-based utility functions

2016-11-29 Thread David Ahern
On 11/29/16 9:02 AM, Arnaldo Carvalho de Melo wrote: > Humm, I'd prefer 'time_interval' or 'perf_time_interval', plain > 'interval' doesn't convey what kind if interval is this, we could be > talking about counter values intervals, etc. agreed, perf_time_interval makes more sense.

Re: [PATCH 1/6] perf tool: Add time-based utility functions

2016-11-29 Thread Arnaldo Carvalho de Melo
Em Mon, Nov 28, 2016 at 10:27:08AM -0700, David Ahern escreveu: > On 11/28/16 6:58 AM, Jiri Olsa wrote: > > On Fri, Nov 25, 2016 at 02:39:54PM -0700, David Ahern wrote: > > > > SNIP > > > >> diff --git a/tools/perf/util/time-utils.h b/tools/perf/util/time-utils.h > >> new file mode 100644 > >> in

Re: [PATCH 1/6] perf tool: Add time-based utility functions

2016-11-28 Thread Jiri Olsa
On Mon, Nov 28, 2016 at 10:35:15AM -0700, David Ahern wrote: > On 11/28/16 6:58 AM, Jiri Olsa wrote: > > On Fri, Nov 25, 2016 at 02:39:54PM -0700, David Ahern wrote: > >> From: David Ahern > >> > >> Add function to parse a user time string of the form , > >> where start and stop are time in sec.ns

Re: [PATCH 1/6] perf tool: Add time-based utility functions

2016-11-28 Thread David Ahern
On 11/28/16 11:14 AM, Jiri Olsa wrote: > there are some time related functions in util.[ch], maybe you > coudl move them as well > > int fetch_current_timestamp(char *buf, size_t sz); > int timestamp__scnprintf_usec(u64 timestamp, char *buf, size_t sz); I'd like to defer that to a follow on patch

Re: [PATCH 1/6] perf tool: Add time-based utility functions

2016-11-28 Thread David Ahern
On 11/28/16 6:58 AM, Jiri Olsa wrote: > On Fri, Nov 25, 2016 at 02:39:54PM -0700, David Ahern wrote: >> From: David Ahern >> >> Add function to parse a user time string of the form , >> where start and stop are time in sec.nsec format. Both start and stop >> times are optional. >> >> Add function

Re: [PATCH 1/6] perf tool: Add time-based utility functions

2016-11-28 Thread David Ahern
On 11/28/16 6:58 AM, Jiri Olsa wrote: > On Fri, Nov 25, 2016 at 02:39:54PM -0700, David Ahern wrote: > > SNIP > >> diff --git a/tools/perf/util/time-utils.h b/tools/perf/util/time-utils.h >> new file mode 100644 >> index ..4368a481251d >> --- /dev/null >> +++ b/tools/perf/util/time-ut

Re: [PATCH 1/6] perf tool: Add time-based utility functions

2016-11-28 Thread Jiri Olsa
On Fri, Nov 25, 2016 at 02:39:54PM -0700, David Ahern wrote: SNIP > diff --git a/tools/perf/util/time-utils.h b/tools/perf/util/time-utils.h > new file mode 100644 > index ..4368a481251d > --- /dev/null > +++ b/tools/perf/util/time-utils.h > @@ -0,0 +1,12 @@ > +#ifndef _TIME_UTILS_H_

Re: [PATCH 1/6] perf tool: Add time-based utility functions

2016-11-28 Thread Jiri Olsa
On Fri, Nov 25, 2016 at 02:39:54PM -0700, David Ahern wrote: > From: David Ahern > > Add function to parse a user time string of the form , > where start and stop are time in sec.nsec format. Both start and stop > times are optional. > > Add function to determine if a sample time is within a giv

Re: [PATCH 1/6] perf tool: Add time-based utility functions

2016-11-28 Thread Jiri Olsa
On Fri, Nov 25, 2016 at 02:39:54PM -0700, David Ahern wrote: > From: David Ahern > > Add function to parse a user time string of the form , > where start and stop are time in sec.nsec format. Both start and stop > times are optional. > > Add function to determine if a sample time is within a giv