From owner-freebsd-current Sun May 24 22:41:13 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id WAA22005 for freebsd-current-outgoing; Sun, 24 May 1998 22:41:13 -0700 (PDT) (envelope-from owner-freebsd-current@FreeBSD.ORG) Received: from dyson.iquest.net (dyson.iquest.net [198.70.144.127]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id WAA21985; Sun, 24 May 1998 22:40:39 -0700 (PDT) (envelope-from toor@dyson.iquest.net) Received: (from root@localhost) by dyson.iquest.net (8.8.8/8.8.8) id AAA02151; Mon, 25 May 1998 00:40:21 -0500 (EST) (envelope-from toor) Message-Id: <199805250540.AAA02151@dyson.iquest.net> Subject: Re: cvs commit: src/sys/nfs nfs.h nfs_node.c nfs_nqlease.c nfs_subs.c nfs_vfsops.c In-Reply-To: <199805250511.NAA19722@spinner.netplex.com.au> from Peter Wemm at "May 25, 98 01:11:41 pm" To: peter@netplex.com.au (Peter Wemm) Date: Mon, 25 May 1998 00:40:18 -0500 (EST) Cc: dyson@FreeBSD.ORG, dima@xyzzy.machaon.ru, peter@FreeBSD.ORG, current@FreeBSD.ORG, dima@bog.msu.su From: "John S. Dyson" Reply-To: dyson@FreeBSD.ORG X-Mailer: ELM [version 2.4ME+ PL38 (25)] MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG Peter Wemm said: > > Perhaps we should do some sort of periodic reclaim of unused zone pages? I > was planning on moving some of the other nfs structs to zones as well, > especially those that are allocated and freed by the tens or hundreds of > thousands of times per "busy" session (eg: doing a cvs update over nfs). > The 'never freed' bit worrys me a little since these can be busty and ^^^^^^^^^^^^^ > temporarily larger than usual. The speed of zone based allocation will be > nice here, since one one machine that's been running with some nfs activity > over a day or two has clocked up 300K requests for a 64 byte object, and > yet the high water mark is only 1KB. I'd be happy to trade an entire page > to supercharge that. :-) > Malloc doesn't free things effectively either. Making zone "free" pages on the fly would require a significant increase in the amount of logic. To make it do a "garbage collection-style" operation would be easier, and I am not adverse to it. As it is today, it won't be much worse (if any) than malloc is. (Once a piece of memory is committed to a certain size, it is going to be that size forever in malloc. The zone allocator commits a piece of memory to a "type" instead of a size. In both cases, the memory will remain wired for the lifetime of the system.) At one time, a long time ago, I taught malloc to free memory back to the system, and it didn't help much. Maybe sometime in the future, we can add a zone attribute to try to free memory when it seems to be a good thing to do (as you suggest) (perhaps when the pageout daemon decides to.) -- John | Never try to teach a pig to sing, dyson@freebsd.org | it just makes you look stupid, jdyson@nc.com | and it irritates the pig. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message