Re: [COMMITTERS] pgsql: Add pg_sequence system catalog - Mailing list pgsql-committers

From Tom Lane
Subject Re: [COMMITTERS] pgsql: Add pg_sequence system catalog
Date
Msg-id 24589.1482265939@sss.pgh.pa.us
Whole thread Raw
In response to Re: [COMMITTERS] pgsql: Add pg_sequence system catalog  (Peter Eisentraut <peter.eisentraut@2ndquadrant.com>)
List pgsql-committers
Peter Eisentraut <peter.eisentraut@2ndquadrant.com> writes:
> It looks like the catalog data is written without padding (relid(4),
> start(8), inc(8), max(8), min(8), ...) but read with padding (relid(4),
> padding(4), start(8), inc(8), max(8), min(8), ...).  The difference is
> that the write goes through heap_form_tuple but the read uses the Form_
> struct.  What is suspicious is this from the configure output:

> checking alignment of short... 2
> checking alignment of int... 4
> checking alignment of long... 4
> checking alignment of long long int... 8
> checking alignment of double... 4

> We use DOUBLEALIGN to align int64 values, but on this platform, that is
> not correct.

Quickest solution might be to reorder the columns of pg_sequence to
avoid wasting padding bytes, ie, put seqcycle after seqrelid.

            regards, tom lane


pgsql-committers by date:

Previous
From: Peter Eisentraut
Date:
Subject: Re: [COMMITTERS] pgsql: Add pg_sequence system catalog
Next
From: Tom Lane
Date:
Subject: [COMMITTERS] pgsql: Fix minor error message style violation.