lkml.org 
[lkml]   [2021]   [Jan]   [14]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v2 1/2] perf stat: Introduce struct runtime_stat_data
On Thu, Jan 14, 2021 at 12:25:39PM +0900, Namhyung Kim wrote:
> Hi Jiri,
>
> On Wed, Jan 13, 2021 at 8:19 PM Jiri Olsa <jolsa@redhat.com> wrote:
> >
> > On Tue, Jan 12, 2021 at 03:14:30PM +0900, Namhyung Kim wrote:
> > > To pass more info to the saved_value in the runtime_stat, add a new
> > > struct runtime_stat_data. Currently it only has 'ctx' field but later
> > > patch will add more.
> > >
> > > Suggested-by: Andi Kleen <ak@linux.intel.com>
> > > Signed-off-by: Namhyung Kim <namhyung@kernel.org>
> > > ---
> > > tools/perf/util/stat-shadow.c | 346 +++++++++++++++++-----------------
> > > 1 file changed, 173 insertions(+), 173 deletions(-)
> > >
> > > diff --git a/tools/perf/util/stat-shadow.c b/tools/perf/util/stat-shadow.c
> > > index 901265127e36..a1565b6e38f2 100644
> > > --- a/tools/perf/util/stat-shadow.c
> > > +++ b/tools/perf/util/stat-shadow.c
> > > @@ -114,6 +114,10 @@ static struct saved_value *saved_value_lookup(struct evsel *evsel,
> > >
> > > rblist = &st->value_list;
> > >
> > > + /* don't use context info for clock events */
> > > + if (type == STAT_NSECS)
> > > + dm.ctx = 0;
> > > +
> >
> > I think this should go to separate patch and be explained,
> > the change is advertised as adding struct for arguments
>
> Actually it was already there and I found it during this work.
> Basically it passes ctx for lookup but it uses 0 for time.
> Please see below..

ah nice, did not see that.. could be mentioned in the changelog ;-)

thanks,
jirka

\
 
 \ /
  Last update: 2021-01-14 14:27    [W:0.075 / U:0.444 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site