Pavel Borisov <pashkin.e...@gmail.com> writes:
>> How can we say that in PageInit the SizeOfPageHeaderData is expected
>> to be max aligned? Am I missing something? There are lots of other
>> places where SizeOfPageHeaderData is used, not
>> MAXALIGN(SizeOfPageHeaderData).

> Its maxalign is ensured by its size of 24bytes (which is maxalign'ed). I
> think if we change this to not-maxalign'ed value bad things can happen. So
> I've added assert checking for this value. I think it is similar situation
> for both page header and page special, I wonder why they've been treated
> differently in PageInit.

No, that's wrong.  What follows the page header is the line pointer
array, which is only int-aligned.  We need to maxalign the special
space because tuples are stored working backwards from that, and
we want maxalignment for tuples.

                        regards, tom lane


Reply via email to