freebsd-dev/sys/cddl/contrib/opensolaris
Andriy Gapon c59690f249 zfs+sendfile: populate all requested pages, not just those already cached
kern_sendfile() uses vm_rdwr() to read-ahead blocks of data to populate
page cache.  When sendfile stumbles upon a page that is not populated
yet, it sends out all the mbufs that it collected so far.  This
resulted in very poor performance with ZFS when file data is not in the
page cache, because ZFS vop_read for UIO_NOCOPY case populated only
those pages that are already in cache, but not valid.  Which means that
most of the time it populated only the first requested page in the
described above scenario.

Reported by:	Alexander Zagrebin <alexz@visp.ru>
Tested by:	Alexander Zagrebin <alexz@visp.ru>,
		Artemiev Igor <ai@kliksys.ru>
MFC after:	12 days
2010-11-16 15:53:44 +00:00
..
common Add OpenSolaris atomics for powerpc64 and connect ZFS to the build on 2010-07-17 13:34:01 +00:00
uts zfs+sendfile: populate all requested pages, not just those already cached 2010-11-16 15:53:44 +00:00
OPENSOLARIS.LICENSE Now that we have CDDLed code in the tree, add CDDL license. 2007-09-23 07:04:50 +00:00