From owner-freebsd-questions@FreeBSD.ORG Fri Aug 3 20:04:30 2007 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 00C0716A419 for ; Fri, 3 Aug 2007 20:04:30 +0000 (UTC) (envelope-from wojtek@wojtek.tensor.gdynia.pl) Received: from wojtek.tensor.gdynia.pl (wojtek.tensor.gdynia.pl [IPv6:2001:4070:101:2::1]) by mx1.freebsd.org (Postfix) with ESMTP id 921D813C442 for ; Fri, 3 Aug 2007 20:04:25 +0000 (UTC) (envelope-from wojtek@wojtek.tensor.gdynia.pl) Received: from wojtek.tensor.gdynia.pl (localhost [IPv6:::1]) by wojtek.tensor.gdynia.pl (8.13.8/8.13.8) with ESMTP id l73K4I4e019344; Fri, 3 Aug 2007 22:04:18 +0200 (CEST) (envelope-from wojtek@wojtek.tensor.gdynia.pl) Received: from localhost (wojtek@localhost) by wojtek.tensor.gdynia.pl (8.13.8/8.13.8/Submit) with ESMTP id l73K4IZG019341; Fri, 3 Aug 2007 22:04:18 +0200 (CEST) (envelope-from wojtek@wojtek.tensor.gdynia.pl) Date: Fri, 3 Aug 2007 22:04:18 +0200 (CEST) From: Wojciech Puchar To: Kris Kennaway In-Reply-To: <20070803164621.GA65921@rot26.obsecurity.org> Message-ID: <20070803220027.C19191@wojtek.tensor.gdynia.pl> References: <20070803172639.F17414@wojtek.tensor.gdynia.pl> <20070803164621.GA65921@rot26.obsecurity.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed Cc: freebsd-questions@freebsd.org Subject: Re: parformance patch? X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 03 Aug 2007 20:04:30 -0000 >> -#define MAXPHYS (128 * 1024) /* max raw I/O transfer >> size */ >> +#define MAXPHYS (512 * 1024) /* max raw I/O transfer >> size */ >> both works for me and gives noticable speedup, when operating on big files >> and when starting big apps or swapping. > > There are assumptions about the value of MAXPHYS all through the > kernel. I doubt this patch works properly - it is something that > should be fixed more completely though. funny but THIS patch (MAXPHYS, not other) is working for me on 4 heavily loaded servers for over a year with FreeBSD 6.2 while vm patch is running on my notebook for 2 days only, ok for now but still testing. > >> other question (swap_pager.c): >> >> /* >> * SWB_NPAGES must be a power of 2. It may be set to 1, 2, 4, 8, or 16 >> * pages per allocation. We recommend you stick with the default of 8. >> * The 16-page limit is due to the radix code (kern/subr_blist.c). >> */ >> >> #ifndef MAX_PAGEOUT_CLUSTER >> #define MAX_PAGEOUT_CLUSTER 16 >> #endif >> >> >> >> can this be changed/fixed? 64-128 would be nicer... > > Why? i.e. what are the implications of this, good and bad? > 16*4=64kbytes for modern disk drives 64 kbytes is transferred below 1 milisecond, while seek takes 8-10ms by average. doing so small I/O is inefficient. something like 512kB (128 pages) looks better. patched vm_fault make pageins faster, but not pageout. disks often does write caching clustering pageouts anyway, but probably not that efficient.