From owner-freebsd-current@FreeBSD.ORG Wed Aug 18 10:43:20 2010 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 2CA1D1065674; Wed, 18 Aug 2010 10:43:20 +0000 (UTC) (envelope-from pluknet@gmail.com) Received: from mail-qy0-f175.google.com (mail-qy0-f175.google.com [209.85.216.175]) by mx1.freebsd.org (Postfix) with ESMTP id BE6288FC1B; Wed, 18 Aug 2010 10:43:19 +0000 (UTC) Received: by qyk11 with SMTP id 11so1873380qyk.13 for ; Wed, 18 Aug 2010 03:43:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:received:in-reply-to :references:date:message-id:subject:from:to:cc:content-type; bh=v5bJvJytD07WX2ZukXwKaUOzSfm3rVPIle2wC9vhVAM=; b=uSViCiIb5VMNihVNJm3W6qG5iPcYPpfXfjxAuogJx/aNVz77xZsQbju7RtUE/wZm4c FYob5PDTssd6Lf9CXxx0HT2TbRyzwE08LMPAm/SWiGWaXzdJAW5O3p4GCek+Q34zChHO +32ay7WqpBgsq1EYjmmyG6rF0iRR/WleAJfm4= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; b=rBwS0YdOecYkIEjf9oLHZZFpVCkarGsmLnQzaEr8Jaxs6KdCLf4p27m1qkxgMFUlPA QNnhCN+0AdpKfB1fxwXIKP7ltPG2A7gjppsvcWu0RrXHe/o+MwahSwB0p8uu4TPlKj75 edX1odSDNrTxVYjBTXeBrO9tCF/jy70x3ftls= MIME-Version: 1.0 Received: by 10.224.28.129 with SMTP id m1mr5312863qac.113.1282128199075; Wed, 18 Aug 2010 03:43:19 -0700 (PDT) Received: by 10.229.31.12 with HTTP; Wed, 18 Aug 2010 03:43:19 -0700 (PDT) In-Reply-To: References: <20100816185456.GU2396@deviant.kiev.zoral.com.ua> <20100817160445.GO2396@deviant.kiev.zoral.com.ua> Date: Wed, 18 Aug 2010 14:43:19 +0400 Message-ID: From: pluknet To: Kostik Belousov Content-Type: multipart/mixed; boundary=0015175cb21edccb15048e16bb7b Cc: FreeBSD Current Subject: Re: LOR on nfs: vfs_vnops.c:301 kern_descrip.c:1580 X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 18 Aug 2010 10:43:20 -0000 --0015175cb21edccb15048e16bb7b Content-Type: text/plain; charset=ISO-8859-1 On 18 August 2010 12:07, pluknet wrote: > On 17 August 2010 20:04, Kostik Belousov wrote: > >> >> Also please take a note of the John' suggestion to use the taskqueue. > > I decided to go this road. Thank you both. > Now I do nfs buildkernel survive and prepare some benchmark results. > So, I modified the patch to defer proc_create() with taskqueue(9). Below is `time make -j5 buildkernel WITHOUT_MODULES=yes` perf. evaluation. Done on 4-way CPU on clean /usr/obj with /usr/src & /usr/obj both nfs-mounted over 1Gbit LAN. clean old 1137.985u 239.411s 7:42.15 298.0% 6538+2133k 87+43388io 226pf+0w clean new 1134.755u 240.032s 7:41.25 298.0% 6553+2133k 87+43367io 224pf+0w Patch needs polishing, though it generally works. Not sure if shep_chan (or whatever name it will get) needs locking. -- wbr, pluknet --0015175cb21edccb15048e16bb7b Content-Type: application/octet-stream; name="nfsiod_tq.diff" Content-Disposition: attachment; filename="nfsiod_tq.diff" Content-Transfer-Encoding: base64 X-Attachment-Id: f_gd01toqi0 SW5kZXg6IHN5cy9uZnNjbGllbnQvbmZzX3Zub3BzLmMKPT09PT09PT09PT09PT09PT09PT09PT09 PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PQotLS0gc3lzL25mc2Ns aWVudC9uZnNfdm5vcHMuYwkocmV2aXNpb24gMj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