Re: page macros cleanup

"Heikki Linnakangas" <[email protected]>
Newsgroups gmane.comp.db.postgresql.devel.patches
Organization EnterpriseDB
Message-ID <[email protected]>
Zdenek Kotala wrote:
> By my opinion first place where tuple should be placed is:
> 
> MAXALIGN(SizeOfPageHeaderData + sizeof(ItemIdData))

Yeah, but we don't enforce that directly. We enforce it by MAXALIGNing 
size in PageAddItem, and with the rule that special-size is MAXALIGNed.

To put it another way, it's possible that there's an unaligned amount of 
free space on a page, as returned by PageGetExactFreeSpace. But since 
item size is always MAXALIGNed, it's impossible to use it all.


Come to think of it, why do we require MAXALIGN alignment of tuples? I 
must be missing something, but AFAICS the widest fields in 
HeapTupleHeaderData are 4-bytes wide, so it should be possible to get 
away with 4-byte alignment.

-- 
   Heikki Linnakangas
   EnterpriseDB   http://www.enterprisedb.com

-- 
Sent via pgsql-patches mailing list ([email protected])
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-patches
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.