Received: from localhost (unknown [200.46.204.182]) by postgresql.org (Postfix) with ESMTP id D32779F9EA1 for ; Mon, 8 Oct 2007 18:22:28 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.182]) (amavisd-maia, port 10024) with ESMTP id 73067-02 for ; Mon, 8 Oct 2007 18:22:22 -0300 (ADT) X-Greylist: from auto-whitelisted by SQLgrey-1.7.5 Received: from mailbox.samurai.com (mailbox.samurai.com [205.207.28.82]) by postgresql.org (Postfix) with ESMTP id AED139F9626 for ; Mon, 8 Oct 2007 18:22:25 -0300 (ADT) Received: from localhost (mailbox.samurai.com [205.207.28.82]) by mailbox.samurai.com (Postfix) with ESMTP id EDA2861D30; Mon, 8 Oct 2007 17:22:23 -0400 (EDT) X-Virus-Scanned: by amavisd-new at mailbox.samurai.com Received: from mailbox.samurai.com ([205.207.28.82]) by localhost (mailbox.samurai.com [205.207.28.82]) (amavisd-new, port 10024) with LMTP id p1fMQUxT-5mp; Mon, 8 Oct 2007 17:22:19 -0400 (EDT) Received: from [10.10.30.139] (204.11.227.33.static.etheric.net [204.11.227.33]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mailbox.samurai.com (Postfix) with ESMTP id 1D0FF61D0D; Mon, 8 Oct 2007 17:22:19 -0400 (EDT) Subject: Re: PG on NFS may be just a bad idea From: Neil Conway To: Alvaro Herrera Cc: Bruce Momjian , Tom Lane , Simon Riggs , Josh Berkus , pgsql-hackers@postgresql.org, Mija Lee In-Reply-To: <20071008205035.GF6000@alvh.no-ip.org> References: <20071001234651.GD9430@alvh.no-ip.org> <200710082046.l98KkQj28574@momjian.us> <20071008205035.GF6000@alvh.no-ip.org> Content-Type: text/plain Date: Mon, 08 Oct 2007 14:22:17 -0700 Message-Id: <1191878537.26227.4.camel@dell.linuxdev.us.dell.com> Mime-Version: 1.0 X-Mailer: Evolution 2.12.0 Content-Transfer-Encoding: 7bit X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200710/262 X-Sequence-Number: 108630 On Mon, 2007-10-08 at 16:50 -0400, Alvaro Herrera wrote: > palloc uses malloc underneath. My thought is to replace that with > sbrk, mmap or something like that. Not very portable though, a lot of > work, and most likely not nearly enough benefits. Yeah, I agree this isn't likely to be a win in the general case. However, it would be interesting to explore a specialized allocator for short-lived memory contexts, where we don't care about having an effective pfree(). If the context is going to be reset or deleted shortly anyway, we could probably optimize and simplify palloc() by skipping free space accounting and then make pfree() a no-op. I recall Tom mentioning something to this effect a few months back... -Neil