From owner-svn-src-projects@FreeBSD.ORG Mon Dec 2 06:12:35 2013 Return-Path: Delivered-To: svn-src-projects@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 10550113; Mon, 2 Dec 2013 06:12:35 +0000 (UTC) Received: from cell.glebius.int.ru (glebius.int.ru [81.19.69.10]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 8D14F143C; Mon, 2 Dec 2013 06:12:33 +0000 (UTC) Received: from cell.glebius.int.ru (localhost [127.0.0.1]) by cell.glebius.int.ru (8.14.7/8.14.7) with ESMTP id rB26CV11051305 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Mon, 2 Dec 2013 10:12:32 +0400 (MSK) (envelope-from glebius@FreeBSD.org) Received: (from glebius@localhost) by cell.glebius.int.ru (8.14.7/8.14.7/Submit) id rB26CVM9051304; Mon, 2 Dec 2013 10:12:31 +0400 (MSK) (envelope-from glebius@FreeBSD.org) X-Authentication-Warning: cell.glebius.int.ru: glebius set sender to glebius@FreeBSD.org using -f Date: Mon, 2 Dec 2013 10:12:31 +0400 From: Gleb Smirnoff To: Julian Elischer Subject: Re: svn commit: r258815 - projects/sendfile/sys/kern Message-ID: <20131202061231.GC48919@FreeBSD.org> References: <201312012110.rB1LA7MW008020@svn.freebsd.org> <529BCB70.3000308@freebsd.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <529BCB70.3000308@freebsd.org> User-Agent: Mutt/1.5.22 (2013-10-16) Cc: svn-src-projects@freebsd.org, src-committers@freebsd.org X-BeenThere: svn-src-projects@freebsd.org X-Mailman-Version: 2.1.16 Precedence: list List-Id: "SVN commit messages for the src " projects" tree" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 02 Dec 2013 06:12:35 -0000 On Mon, Dec 02, 2013 at 07:51:12AM +0800, Julian Elischer wrote: J> On 12/2/13, 5:10 AM, Gleb Smirnoff wrote: J> > Author: glebius J> > Date: Sun Dec 1 21:10:07 2013 J> > J> > Basic performance testing showed no regressions in timing. Number of I/Os J> > decreased comparing to sendfile() from head, but increased compared to J> > previous version of the projects/sendfile. On a sample 300 Mb file: J> > J> > I/Os J> > head 3247 J> > projects/sendfile 680 J> > new code 2826 J> > J> > J> is there planned future work to reduce the number of reads to the same J> order as the previous prototype? J> (i.e. around 1000 or less vs around 3000) I should have noticed that this is 'netstat -m' output, number of sendfile initiated I/Os, not disk statistics. The number of IOs isn't the Graal we are seeking for. Graal is overall performance. Previous version of branch counted VOP_READs. They were large enough, up to the size of the socket buffer. But apparently lower filesystem code split them into smaller. Now we count vm_pager_get_pages(), but amount of pages we pass to it is hinted by vm_pager_has_page(). And the latter hints us about how many pages can it grab with a single disk I/O. -- Totus tuus, Glebius.