[ofa-general] Re: [PATCH][TRIVIAL] opensm/osm_port_profile: No need to inline some functions

Hal Rosenstock hrosenstock at xsigo.com
Wed Jun 25 08:07:38 PDT 2008


On Tue, 2008-06-24 at 03:33 +0300, Sasha Khapyorsky wrote:
> On 07:01 Mon 23 Jun     , Hal Rosenstock wrote:
> > 
> > Inlining is only a hint to the compiler and given the over(ab)use of
> > inline in OpenSM (by my count almost 500 instances) I doubt this has the
> > intended effect.
> 
> I asked in order to understand about are there any specific reasons for
> this patch or just it is "nice to have" stuff (and not to mark my
> disagreement).

Right now, these are nice to have but maybe are needed for future
changes and trying to judge the waters in terms of inline use. I was
also experimenting with some header inclusion issues I ran into.

> > Are the inlines really needed in these two cases ?
> 
> Inlining is potential optimization and as you said it is optional, so
> word "needed" is not the best which describes this :)

Yes, in the sense you indicate needed doesn't apply but the sense I
meant are those specific uses of the inline needed but I don't want to
argue semantics.

> I likely fine about the first case (especially about
> osm_port_prof_set_ignored_port()), but the second function really looks
> as "one-line stuff" for me.

By second function, I presume you are referring to
osm_port_prof_is_ignored_port. I'm not sure what you mean by "one line
stuff" but maybe that also applies to the other patch relating to inline
(opensm/osm_switch: Don't inline osm_switch_sp0_is_lmc_capable
function).

-- Hal 

> > In general, I think OpenSM needs a more careful look as to what really
> > needs inlining.
> 
> Sure. Agreed here.
> 
> > > Would be nice to not mix in one patch.
> > 
> > Already done on list.
> 
> Thanks.
> 
> Sasha
> _______________________________________________
> general mailing list
> general at lists.openfabrics.org
> http://lists.openfabrics.org/cgi-bin/mailman/listinfo/general
> 
> To unsubscribe, please visit http://openib.org/mailman/listinfo/openib-general




More information about the general mailing list