lkml.org 
[lkml]   [2017]   [Nov]   [22]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v1 3/9] perf util: Reconstruct rblist for supporting per-thread shadow stats
On Wed, Nov 22, 2017 at 09:29:26AM +0800, Jin, Yao wrote:
>
>
> On 11/21/2017 11:17 PM, Jiri Olsa wrote:
> > On Mon, Nov 20, 2017 at 10:43:38PM +0800, Jin Yao wrote:
> >
> > SNIP
> >
> > > +static void init_saved_rblist(struct rblist *rblist)
> > > +{
> > > + rblist__init(rblist);
> > > + rblist->node_cmp = saved_value_cmp;
> > > + rblist->node_new = saved_value_new;
> > > + rblist->node_delete = saved_value_delete;
> > > +}
> > > +
> > > +static void free_saved_rblist(struct rblist *rblist)
> > > +{
> > > + rblist__reset(rblist);
> > > +}
> > > +
> > > +void perf_stat__init_runtime_stat(struct runtime_stat *stat)
> > > +{
> > > + memset(stat, 0, sizeof(struct runtime_stat));
> >
> > what's this memset for? that struct has only rb_list
> >
> > jirka
> >
>
> Currently this struct has only rblist. I use memset to zero this struct is
> for future potential new added fields to this struct.
>
> If it's not good, I will remove this memset.

ok, np

jirka

\
 
 \ /
  Last update: 2017-11-22 09:30    [W:0.074 / U:0.064 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site