Re: Re: [COMMITTERS] pgsql: Properly access a buffer's LSN using existing access macros - Mailing list pgsql-hackers

From Tom Lane
Subject Re: Re: [COMMITTERS] pgsql: Properly access a buffer's LSN using existing access macros
Date
Msg-id 5757.1224543244@sss.pgh.pa.us
Whole thread Raw
In response to Re: [COMMITTERS] pgsql: Properly access a buffer's LSN using existing access macros  (Alvaro Herrera <alvherre@commandprompt.com>)
List pgsql-hackers
Alvaro Herrera <alvherre@commandprompt.com> writes:
> Hmm, I just noticed this comment in bufpage.h (which was also in Jonah's
> patch) :-(

> typedef struct PageHeaderData
> {
>     /* XXX LSN is member of *any* block, not only page-organized ones */
>     ...

We don't have any non-page-organized blocks ;-)

Seriously, if the issue ever became significant I'd expect that we'd add
a buffer flag to tell whether the buffer had a LSN or not, and set this
appropriately at buffer readin time depending on where we got the page
from.  That would then cue the write logic to know what to do.  (In
particular, I suppose we'd need to do this if we try to migrate clog and
friends into the main buffer arena.)
        regards, tom lane


pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: [GENERAL] Hot Standby utility and administrator functions
Next
From: "Lawrence, Ramon"
Date:
Subject: Proposed Patch to Improve Performance of Multi-Batch Hash Join for Skewed Data Sets