Re: GIN needs tonic - Mailing list pgsql-bugs

From Tom Lane
Subject Re: GIN needs tonic
Date
Msg-id 13269.1253030998@sss.pgh.pa.us
Whole thread Raw
In response to Re: GIN needs tonic  (Heikki Linnakangas <heikki.linnakangas@enterprisedb.com>)
Responses Re: GIN needs tonic  (Simon Riggs <simon@2ndQuadrant.com>)
List pgsql-bugs
Heikki Linnakangas <heikki.linnakangas@enterprisedb.com> writes:
> Tom Lane wrote:
>> Actually, the entire thing is misdesigned from the get-go.  AFAICS
>> it shouldn't even have its own WAL record type --- it should be using
>> log_newpage().

> Yeah, that would be even simpler. The WAL records it currenctly writes
> are more compact, but then again it probably makes no difference in
> practice.

I'm working on this now.  It looks to me like there are a number of bugs
in this code, notably I think that the accounting for free space on
GinList pages is failing to allow for alignment effects.

One difficulty in using log_newpage() directly is that it presently
assumes that the page it's passed has been built in private memory,
not in a shared buffer.  I'm not sure if it's worth restructuring the
GIN code to do it that way.

            regards, tom lane

pgsql-bugs by date:

Previous
From: Heikki Linnakangas
Date:
Subject: Re: GIN needs tonic
Next
From: Tom Lane
Date:
Subject: Re: error: message type 0x5a arrived from server while idle