Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 22 Aug 2007 17:37:50 +0300
From:      "Ivo Vachkov" <ivo.vachkov@gmail.com>
To:        "Bruce M. Simpson" <bms@freebsd.org>
Cc:        freebsd-net <freebsd-net@freebsd.org>
Subject:   Re: Route caching ?
Message-ID:  <f85d6aa70708220737p28fb6260h699754544ccd249a@mail.gmail.com>
In-Reply-To: <46CC475F.8030505@FreeBSD.org>
References:  <f85d6aa70708220003le893770uca9ceea467d85618@mail.gmail.com> <46CC475F.8030505@FreeBSD.org>

next in thread | previous in thread | raw e-mail | index | archive | help
Actually there is:

struct	route_in6 ip6_forward_rt;

that "caches" the last route used (thanks blue !!!) but i think this
technique is pointless in a multiflow traffic.

Is it reasonable to believe that route caches can improve networking
performance or we should leave it up to the routing table itself ?

On 8/22/07, Bruce M. Simpson <bms@freebsd.org> wrote:
> Not really, at least, not in the way one would think. rtalloc() is a
> legacy function.
>
> ip_output() will still call rtalloc() if you pass it a filled out
> 'struct route', a structure which is not a route, but an internal
> request to look up a route.
>
> This is a wrapper for rtalloc_ign(), which in turn is a wrapper for
> rtalloc1(), the function which does the actual lookup.
>
> rtalloc_ign() is pretty straightforward. Note however that this approach
> only checks the RTF_UP flag and ifp, nothing more. This makes it
> suitable for implementing floating statics, but nothing more dynamic
> than that.
>
> regards,
> BMS
>


-- 
"UNIX is basically a simple operating system, but you have to be a
genius to understand the simplicity." Dennis Ritchie



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?f85d6aa70708220737p28fb6260h699754544ccd249a>