Received: from maia.hub.org (maia-3.hub.org [200.46.204.243]) by mail.postgresql.org (Postfix) with ESMTP id 8AE28B5DC06 for ; Tue, 30 Aug 2011 07:41:13 -0300 (ADT) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.243]) (amavisd-maia, port 10024) with ESMTP id 95107-03 for ; Tue, 30 Aug 2011 10:41:06 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from exprod7og123.obsmtp.com (exprod7og123.obsmtp.com [64.18.2.24]) by mail.postgresql.org (Postfix) with ESMTP id D0B20B5DC54 for ; Tue, 30 Aug 2011 07:41:05 -0300 (ADT) Received: from mail-fx0-f54.google.com ([209.85.161.54]) (using TLSv1) by exprod7ob123.postini.com ([64.18.6.12]) with SMTP ID DSNKTly+QNU/LGSxfUeE4YY8va30LNq/Aq0f@postini.com; Tue, 30 Aug 2011 03:41:06 PDT Received: by fxe4 with SMTP id 4so6783856fxe.13 for ; Tue, 30 Aug 2011 03:41:03 -0700 (PDT) Received: by 10.223.94.147 with SMTP id z19mr8768025fam.107.1314700863060; Tue, 30 Aug 2011 03:41:03 -0700 (PDT) Received: from [192.168.1.183] (dsl-hkibrasgw2-ff7ac300-240.dhcp.inet.fi [88.195.122.240]) by mx.google.com with ESMTPS id 22sm4479868fay.28.2011.08.30.03.41.01 (version=TLSv1/SSLv3 cipher=OTHER); Tue, 30 Aug 2011 03:41:02 -0700 (PDT) Message-ID: <4E5CBE3C.6030404@enterprisedb.com> Date: Tue, 30 Aug 2011 13:41:00 +0300 From: Heikki Linnakangas User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; fi-FI; rv:1.9.2.20) Gecko/20110820 Icedove/3.1.12 MIME-Version: 1.0 To: Alexander Korotkov CC: Robert Haas , pgsql-hackers Subject: Re: WIP: Fast GiST index build References: <4E42DFCE.3050904@enterprisedb.com> <4E4AAC49.7070401@enterprisedb.com> <4E4AC0B9.8070203@enterprisedb.com> <4E4AC1C3.4070003@enterprisedb.com> <4E569D9A.4020308@enterprisedb.com> <4E5CA88C.50008@enterprisedb.com> <4E5CA9C5.1030708@enterprisedb.com> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-1.9 tagged_above=-5 required=5 tests=BAYES_00=-1.9 X-Spam-Level: X-Archive-Number: 201108/1325 X-Sequence-Number: 194080 On 30.08.2011 13:29, Alexander Korotkov wrote: > On Tue, Aug 30, 2011 at 1:13 PM, Heikki Linnakangas< > heikki.linnakangas@enterprisedb.com> wrote: > >> So, over 50% of the CPU time is spent in choosing a block from the >> temporary files. That should be pretty easy to improve.. >> > Yes, probably we can just remove free blocks sorting. I'm re-running the tests with that change now. It seems like using the list of free blocks as a simple stack would be better anyway, it probably yields a better cache hit ratio when we re-use blocks that have just been released. -- Heikki Linnakangas EnterpriseDB http://www.enterprisedb.com