From: Pavan Deolasee <pavan.deolasee@gmail.com>
To: Heikki Linnakangas <heikki@enterprisedb.com>
Cc: Tom Lane <tgl@sss.pgh.pa.us>
Cc: Craig Ringer <craig@postnewspapers.com.au>
Cc: pgsql-patches <pgsql-patches@postgresql.org>
Subject: Re: [PERFORM] Very slow (2 tuples/second) sequential scan after bulk insert; speed returns to ~500 tuples/second after commit
Date: Tue, 11 Mar 2008 18:36:33 +0530
Message-ID: <2e78013d0803110606hb0eaa2aq1784608cf4c7026c@mail.gmail.com> (raw)
In-Reply-To: <47D67C3F.1030406@enterprisedb.com>
References: <47D505AF.4040101@postnewspapers.com.au>
<47D5150C.8090802@enterprisedb.com>
<23588.1205159638@sss.pgh.pa.us>
<47D54A47.3030608@postnewspapers.com.au>
<47D54DB2.4020405@enterprisedb.com>
<24304.1205162440@sss.pgh.pa.us>
<47D67C3F.1030406@enterprisedb.com>
On Tue, Mar 11, 2008 at 6:04 PM, Heikki Linnakangas
<heikki@enterprisedb.com> wrote:
> (moved to pgsql-patches, as there's a patch attached)
>
>
> I couldn't let this case go, so I wrote a patch. I replaced the linked
> list with an array that's enlarged at AtSubCommit_childXids when necessary.
>
We can replace the array of xids with an array of flags where i'th flag is
set to true if the corresponding subtransaction is committed. This would
make lookup O(1) operation. Of course, the downside is when the array
is sparse. Or we can switch to flag based representation once the array size
grows beyond a limit.
Thanks,
Pavan
--
Pavan Deolasee
EnterpriseDB http://www.enterprisedb.com
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-performance@postgresql.org
Cc: pavan.deolasee@gmail.com, heikki@enterprisedb.com, tgl@sss.pgh.pa.us, craig@postnewspapers.com.au, pgsql-patches@postgresql.org
Subject: Re: [PERFORM] Very slow (2 tuples/second) sequential scan after bulk insert; speed returns to ~500 tuples/second after commit
In-Reply-To: <2e78013d0803110606hb0eaa2aq1784608cf4c7026c@mail.gmail.com>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox