Received: from magus.postgresql.org (magus.postgresql.org [87.238.57.229]) by mail.postgresql.org (Postfix) with ESMTP id 697CD1E9AFB1 for ; Mon, 12 Dec 2011 07:16:21 -0400 (AST) Received: from aperol.beccati.com ([93.94.29.238] helo=mail.beccati.com) by magus.postgresql.org with esmtp (Exim 4.72) (envelope-from ) id 1Ra3rl-0004YY-JT for pgsql-bugs@postgresql.org; Mon, 12 Dec 2011 11:16:21 +0000 Received: (qmail 4917 invoked from network); 12 Dec 2011 12:15:45 +0100 Received: from unknown (HELO ?192.168.1.202?) (matteo@beccati.com@88.149.176.119) by mail.beccati.com with SMTP; 12 Dec 2011 11:15:45 -0000 Message-ID: <4EE5E273.8040201@beccati.com> Date: Mon, 12 Dec 2011 12:16:03 +0100 From: Matteo Beccati User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:8.0) Gecko/20111105 Thunderbird/8.0 MIME-Version: 1.0 To: pgsql-bugs@postgresql.org Subject: Re: Postgresql 9.1.2 - abnormal memory usage References: <396904450.20111211221529@erwied.eu> <201112120045.23211.andres@anarazel.de> <201112120145.42463.andres@anarazel.de> <27575.1323671190@sss.pgh.pa.us> <4EE5BB70.4090903@enterprisedb.com> In-Reply-To: <4EE5BB70.4090903@enterprisedb.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Pg-Spam-Score: -4.2 (----) X-Archive-Number: 201112/78 X-Sequence-Number: 31889 Hi Heikki, On 12/12/2011 09:29, Heikki Linnakangas wrote: > On 12.12.2011 08:26, Tom Lane wrote: >> Andres Freund writes: >>> In 3b8161723c645853021b57330dd2ea0484ec6131 Heikki made DatumGetInetP >>> unpack >>> toasted values. Unfortunately the btree support functions for the >>> inet type >>> didn't free memory which they have to do in contrast to about >>> everything else. >> >>> I fixed a few more functions than strictly necessary but I guess >>> thats ok. >> >> Seems like the correct fix is to revert these functions to the former >> behavior, ie they should be using the PP macros not the unpacking ones. > > Agreed, there's no need to unpack here. Fixed, thanks for the report! Just to clarify, am I correct assuming that the issue does not affect tables which have non-indexed inet fields? Cheers -- Matteo Beccati Development & Consulting - http://www.beccati.com/