netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/7] Deconstruct struct fib_result
@ 2012-07-28  4:18 David Miller
  2012-07-28  6:41 ` Alexander Duyck
  2012-07-31 17:27 ` Alexander Duyck
  0 siblings, 2 replies; 5+ messages in thread
From: David Miller @ 2012-07-28  4:18 UTC (permalink / raw)
  To: alexander.duyck; +Cc: eric.dumazet, netdev


This patch set tries to move towards reducing struct fib_result down
to it's absolute minimum.

The eventual idea is to make it so that fib_lookup() simply
returns a "struct fib_nh *" and pointer encoded errnos, instead
of writing into a complicated structure as the return value on
the stack as is done now.

Signed-off-by: David S. Miller <davem@davemloft.net>

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH 0/7] Deconstruct struct fib_result
  2012-07-28  4:18 [PATCH 0/7] Deconstruct struct fib_result David Miller
@ 2012-07-28  6:41 ` Alexander Duyck
  2012-07-28  6:55   ` David Miller
  2012-07-31 17:27 ` Alexander Duyck
  1 sibling, 1 reply; 5+ messages in thread
From: Alexander Duyck @ 2012-07-28  6:41 UTC (permalink / raw)
  To: David Miller; +Cc: eric.dumazet, netdev

On Fri, Jul 27, 2012 at 9:18 PM, David Miller <davem@davemloft.net> wrote:
>
> This patch set tries to move towards reducing struct fib_result down
> to it's absolute minimum.
>
> The eventual idea is to make it so that fib_lookup() simply
> returns a "struct fib_nh *" and pointer encoded errnos, instead
> of writing into a complicated structure as the return value on
> the stack as is done now.
>
> Signed-off-by: David S. Miller <davem@davemloft.net>

I was wondering why you couldn't wrap the tclassid value in result
with an #ifdef CONFIG_IP_ROUTE_CLASSID so that it is stripped if you
don't have that defined?  I did a quick grep through the kernel and it
seems like there are only a few spots that are accessing it without
the define being checked and most of those are just setting it to 0.

Also is there any specific reason to be passing the trie pointer to
check_leaf?  From what I can tell it looks like that it is just used
for updating the trie stats that are stripped if we want performance,
and the trie pointer should be retrievable via the fib table pointer
if we really wanted it anyway.

Thanks,

Alex

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH 0/7] Deconstruct struct fib_result
  2012-07-28  6:41 ` Alexander Duyck
@ 2012-07-28  6:55   ` David Miller
  0 siblings, 0 replies; 5+ messages in thread
From: David Miller @ 2012-07-28  6:55 UTC (permalink / raw)
  To: alexander.duyck; +Cc: eric.dumazet, netdev

From: Alexander Duyck <alexander.duyck@gmail.com>
Date: Fri, 27 Jul 2012 23:41:50 -0700

> I was wondering why you couldn't wrap the tclassid value in result
> with an #ifdef CONFIG_IP_ROUTE_CLASSID so that it is stripped if you
> don't have that defined?

I am so over these feature ifdefs in the routing code, because
realistically everyone turns all the crap on.  Therefore we have to be
optimal when it's all on.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH 0/7] Deconstruct struct fib_result
  2012-07-28  4:18 [PATCH 0/7] Deconstruct struct fib_result David Miller
  2012-07-28  6:41 ` Alexander Duyck
@ 2012-07-31 17:27 ` Alexander Duyck
  2012-07-31 21:43   ` David Miller
  1 sibling, 1 reply; 5+ messages in thread
From: Alexander Duyck @ 2012-07-31 17:27 UTC (permalink / raw)
  To: David Miller; +Cc: eric.dumazet, netdev

On Fri, Jul 27, 2012 at 9:18 PM, David Miller <davem@davemloft.net> wrote:
>
> This patch set tries to move towards reducing struct fib_result down
> to it's absolute minimum.
>
> The eventual idea is to make it so that fib_lookup() simply
> returns a "struct fib_nh *" and pointer encoded errnos, instead
> of writing into a complicated structure as the return value on
> the stack as is done now.
>
> Signed-off-by: David S. Miller <davem@davemloft.net>

I tested these patches most of yesterday and I haven't seen any
issues.  Then again I haven't seen much of an improvement either.

Tested-by: Alexander Duyck <alexander.h.duyck@intel.com>

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH 0/7] Deconstruct struct fib_result
  2012-07-31 17:27 ` Alexander Duyck
@ 2012-07-31 21:43   ` David Miller
  0 siblings, 0 replies; 5+ messages in thread
From: David Miller @ 2012-07-31 21:43 UTC (permalink / raw)
  To: alexander.duyck; +Cc: eric.dumazet, netdev

From: Alexander Duyck <alexander.duyck@gmail.com>
Date: Tue, 31 Jul 2012 10:27:40 -0700

> On Fri, Jul 27, 2012 at 9:18 PM, David Miller <davem@davemloft.net> wrote:
>>
>> This patch set tries to move towards reducing struct fib_result down
>> to it's absolute minimum.
>>
>> The eventual idea is to make it so that fib_lookup() simply
>> returns a "struct fib_nh *" and pointer encoded errnos, instead
>> of writing into a complicated structure as the return value on
>> the stack as is done now.
>>
>> Signed-off-by: David S. Miller <davem@davemloft.net>
> 
> I tested these patches most of yesterday and I haven't seen any
> issues.  Then again I haven't seen much of an improvement either.
> 
> Tested-by: Alexander Duyck <alexander.h.duyck@intel.com>

Thanks for testing.

I'm putting this patch set to the side until I can find a way
to get past the tclassid barrier and also make it show some
difference performance wise.

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2012-07-31 21:43 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-07-28  4:18 [PATCH 0/7] Deconstruct struct fib_result David Miller
2012-07-28  6:41 ` Alexander Duyck
2012-07-28  6:55   ` David Miller
2012-07-31 17:27 ` Alexander Duyck
2012-07-31 21:43   ` David Miller

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).