From: | Robert Haas <robertmhaas(at)gmail(dot)com> |
---|---|
To: | Jeff Davis <pgsql(at)j-davis(dot)com> |
Cc: | Heikki Linnakangas <heikki(dot)linnakangas(at)enterprisedb(dot)com>, Teodor Sigaev <teodor(at)sigaev(dot)ru>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: GIN, partial matches, lossy bitmaps |
Date: | 2009-03-03 02:03:24 |
Message-ID: | 603c8f070903021803y145b1433vfd9a73ee45edffaa@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Mon, Mar 2, 2009 at 3:02 PM, Jeff Davis <pgsql(at)j-davis(dot)com> wrote:
> On Mon, 2009-03-02 at 21:14 +0200, Heikki Linnakangas wrote:
>> If I'm reading the code correctly, item pointers of all matching heap
>> tuples are first collected into a TIDBitmap, and then amgetnext returns
>> tuples from that one by one. If the bitmap becomes lossy, an error is
>> thrown. gingetbitmap is a dummy implementation: it creates a new
>> TIDBitmap and inserts all the tuples from the other TIDBitmap into it
>> one by one, and then returns the new TIDBitmap.
>
> Do you think that might be the cause of the extra startup overhead that
> Robert Haas observed for bitmap scans?
I don't think this is the same thing. My point was that an index scan
wins big time over a bitmap index scan when the index scan doesn't
need to be run to completion - that is, when the query is a semi-join
or an anti-join, or when using LIMIT without ORDER BY.
This is true with or without Teodor's patch, and is the reason why I'm
not sure that removing index scan support is such a great idea.
...Robert
From | Date | Subject | |
---|---|---|---|
Next Message | Robert Treat | 2009-03-03 02:11:55 | Re: Hot standby, running xacts, subtransactions |
Previous Message | Robert Haas | 2009-03-03 01:57:29 | Re: GIN, partial matches, lossy bitmaps |