From owner-freebsd-fs@freebsd.org Tue Mar 29 00:16:25 2016 Return-Path: Delivered-To: freebsd-fs@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id D161BAE0D14 for ; Tue, 29 Mar 2016 00:16:25 +0000 (UTC) (envelope-from glebius@FreeBSD.org) Received: from mailman.ysv.freebsd.org (mailman.ysv.freebsd.org [IPv6:2001:1900:2254:206a::50:5]) by mx1.freebsd.org (Postfix) with ESMTP id BE4721C23 for ; Tue, 29 Mar 2016 00:16:25 +0000 (UTC) (envelope-from glebius@FreeBSD.org) Received: by mailman.ysv.freebsd.org (Postfix) id BA371AE0D0F; Tue, 29 Mar 2016 00:16:25 +0000 (UTC) Delivered-To: fs@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id B7BA1AE0D07 for ; Tue, 29 Mar 2016 00:16:25 +0000 (UTC) (envelope-from glebius@FreeBSD.org) Received: from cell.glebi.us (glebi.us [96.95.210.25]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "cell.glebi.us", Issuer "cell.glebi.us" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 96B381C21; Tue, 29 Mar 2016 00:16:25 +0000 (UTC) (envelope-from glebius@FreeBSD.org) Received: from cell.glebi.us (localhost [127.0.0.1]) by cell.glebi.us (8.15.2/8.15.2) with ESMTPS id u2T0GNS6049254 (version=TLSv1.2 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Mon, 28 Mar 2016 17:16:24 -0700 (PDT) (envelope-from glebius@FreeBSD.org) Received: (from glebius@localhost) by cell.glebi.us (8.15.2/8.15.2/Submit) id u2T0GNQ8049253; Mon, 28 Mar 2016 17:16:23 -0700 (PDT) (envelope-from glebius@FreeBSD.org) X-Authentication-Warning: cell.glebi.us: glebius set sender to glebius@FreeBSD.org using -f Date: Mon, 28 Mar 2016 17:16:23 -0700 From: Gleb Smirnoff To: Bruce Evans Cc: fs@freebsd.org, rmacklem@freebsd.org Subject: Re: nfs pessimized by vnode pages changes Message-ID: <20160329001623.GC2616@FreeBSD.org> References: <20160327144755.Y4269@besplex.bde.org> <20160329090209.Q1020@besplex.bde.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20160329090209.Q1020@besplex.bde.org> User-Agent: Mutt/1.5.24 (2015-08-30) X-BeenThere: freebsd-fs@freebsd.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: Filesystems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 29 Mar 2016 00:16:25 -0000 On Tue, Mar 29, 2016 at 10:59:26AM +1100, Bruce Evans wrote: B> > I debugged another pessimization of nfs. ... B> > ncl_getpages() is now almost always called with a count of 1 page, due B> > to the change changing the count from faultcount to 1 in r292373 in B> > vm_fault(). ... B> I couldn't get full-fs-block input to work right in ncl_getpages(). In B> the old version, vm_fault_hold() almost always calls it with the pages B> for exactly 1 full block, because vm_fault_additional_pages() somehow B> finds this many pages. The last quoted paragraph is a correct observation. According to your investigations, prior to r292373 NFS was doing multiple page pageins, despite it should have reported that it can't. My reading of the code is the same: both before r292373 and after r292373 NFS should page in a single page at request. I quickly reviewed the whole codepath and I can't see how with older code it was able to do multiple page pageins. -- Totus tuus, Glebius.