> -----Original Message-----
> From: Jerin Jacob <jerinjac...@gmail.com>
> Sent: Wednesday, June 7, 2023 9:29 PM
> To: Yan, Zhirun <zhirun....@intel.com>
> Cc: dev@dpdk.org; jer...@marvell.com; kirankum...@marvell.com;
> ndabilpu...@marvell.com; step...@networkplumber.org;
> pbhagavat...@marvell.com; Liang, Cunming <cunming.li...@intel.com>; Wang,
> Haiyue <haiyue.w...@intel.com>; mattias.ronnblom
> <mattias.ronnb...@ericsson.com>
> Subject: Re: [PATCH v9 04/17] graph: add get/set graph worker model APIs
> 
> On Wed, Jun 7, 2023 at 5:55 PM Yan, Zhirun <zhirun....@intel.com> wrote:
> >
> > > > +__rte_experimental
> > > > +static inline uint32_t
> > > > +rte_graph_worker_model_get(struct rte_graph *graph) {
> > > > +       if (!graph_model_is_valid(graph->model))
> > > > +               return -EINVAL;
> > >
> > > Introduce rte_graph_worker_model_no_check_get() to skip this check
> > > to use with fastpath.
> > >
> > > rte_graph_worker_model_get can move to .c file.
> >
> > Yes. Will move in next version.
> > Got it. rte_graph_worker_model_no_check_get() will be used in fast path.
> > Actually, I don’t find the performance impact about static inline, so
> > should the new
> 
> May be due to burst size 32 or 256.it will start impacting if burst size is 
> less.
> 

In my test, the impact still small.
But I understand your point. If the walk() be called much more, it will call 
much get().
The burst size will impact the node->obj[] size, and then cause much walk loop. 
Thanks.

> 
> > API declared with static inline keywords or put it into .c file also?
> 
> Keep in line fastpath function in .h as inline.

The declare of inline is just a suggestion for compiler. The compiler will 
decide to inline or not.
Got it. I will change in next version.

Reply via email to