Date: Wed, 14 Dec 2005 19:40:39 +0200 From: Iasen Kostov <tbyte@otel.net> To: Cedric Tabary <ced@grumly.eu.org> Cc: freebsd-hackers@freebsd.org Subject: Re: mmap() sendfile() Message-ID: <1134582039.40475.0.camel@DraGoN.OTEL.net> In-Reply-To: <20051212172031.GC42322@efrei.fr> References: <20051212083930.GC91837@efrei.fr> <20051212083537.T78724@odysseus.silby.com> <20051212172031.GC42322@efrei.fr>
index | next in thread | previous in thread | raw e-mail
On Mon, 2005-12-12 at 18:20 +0100, Cedric Tabary wrote: > On 12/12/2005 08:38, Mike Silbersack wrote: > > On Mon, 12 Dec 2005, Cedric Tabary wrote: > > > > >If it is true, doing a sendfile() on some very big files (even if not > > >keeping the descriptor open after) will kill the cache ? > > > > > >Please help me to understand why this patch ? and the difference between > > >sendfile() and mmap() at the memory or cache level.. > > > > > >Cédric > > > > My memory escapes me on all the details, but there were two potential > > reasons not to use sendfile with 4.x that no longer apply in 5.x and > > above: > > > > 1. Sendfile used to send small files inefficiently, sending the http > > headers in one packet and the data in another. I fixed this in 5.x. > > > > 2. Alan Cox improved the memory efficiency of sendfile greatly, it now > > uses a single kernel buffer for all copies of the same block of the same > > file, whereas the old implementation made an in-kernel copy of each block, > > making it no more memory efficient than using mbufs. > > What about using sendfile() or mmap() on NFS ? > > Cédric > _______________________________________________ > freebsd-hackers@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-hackers > To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@freebsd.org"help
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?1134582039.40475.0.camel>
