[Bizgres-general] Re: Mapping from bitmap array position to heap
location (was : A bitmap index access method is available...)
Mark Kirkwood
markir at paradise.net.nz
Fri Jan 6 03:33:32 GMT 2006
Jie Zhang wrote:
> On 1/3/06 2:43 AM, "Simon Riggs" <simon at 2ndquadrant.com> wrote:
>
>
>>On Tue, 2006-01-03 at 11:05 +1300, Mark Kirkwood wrote:
>>
>>>Jie Zhang wrote:
>>
>>>>One interesting point is that you choose 2048 as max offset number. Is this
>>>>true for all cases? If so, we can set the word size to 8-bit to further
>>>>increase the bitmap compression rate.
>>
>>>If sizeof(ItemIdData) is always *at least* 4 bytes (which seems
>>>reasonable) then the biggest MaxOffsetNumber can be is 32768/4 = 8192
>>>(i.e if you choose 32K pages).
>>
>>We're always pointing to heap blocks, for which the fixed overhead is
>>always at least another 28 bytes. So the actual maximum with 32K pages
>>is about 1000, even assuming the table is 1 column, nullable, with null
>>value.
>>
>
>
> Thank you both for these explanations. I will test if I can take advantage
> of this.
>
I sanity tested this idea by (re)patching the mapping formulae to use
1024 instead of (MaxOffsetNumber + 1). Seemed to work ok, with index
sizes are performance pretty much identical to the virgin Bizgres code.
I used the default BLCKSZ=8192, so really, another test with it set to
32K is needed to be sure.
Cheers
Mark
More information about the Bizgres-general
mailing list