Re: Block-level CRC checks - Mailing list pgsql-hackers

From Simon Riggs
Subject Re: Block-level CRC checks
Date
Msg-id 1259941984.13774.38500.camel@ebony
Whole thread Raw
In response to Re: Block-level CRC checks  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
On Fri, 2009-12-04 at 10:43 -0500, Tom Lane wrote:
> Simon Riggs <simon@2ndQuadrant.com> writes:
> > As I pointed out here
> > http://archives.postgresql.org/pgsql-hackers/2009-12/msg00056.php
> > we only need to use 3 bits not 4, but it does limit tuple length to 4096
> > for all block sizes. (Two different options there for doing that).
> 
> Limiting the tuple length is a deal-breaker.

If people that use 32kB block sizes exist in practice, I note that
because tuples are at least 4 byte aligned that the first 2 bits of the
length are always unused. So they're available for those with strangely
long tuples, and can be used to signify high order bytes and so max
tuple length could be 16384. With tuples that long, it would be better
to assume 8-byte minimum alignment, which would put max tuple length
back up to 32KB again. None of that need effect people with a standard
8192 byte blocksize.

-- Simon Riggs           www.2ndQuadrant.com



pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Upcoming update releases
Next
From: Tom Lane
Date:
Subject: Re: Block-level CRC checks