Re: Non-deterministic IndexTuple toast compression from index_form_tuple() + amcheck false positives - Mailing list pgsql-hackers

From Tom Lane
Subject Re: Non-deterministic IndexTuple toast compression from index_form_tuple() + amcheck false positives
Date
Msg-id 24596.1547501481@sss.pgh.pa.us
Whole thread Raw
In response to Non-deterministic IndexTuple toast compression fromindex_form_tuple() + amcheck false positives  (Peter Geoghegan <pg@bowt.ie>)
Responses Re: Non-deterministic IndexTuple toast compression fromindex_form_tuple() + amcheck false positives  (Peter Geoghegan <pg@bowt.ie>)
List pgsql-hackers
Peter Geoghegan <pg@bowt.ie> writes:
> The heapallindexed enhancement that made it into Postgres 11 assumes
> that the representation of index tuples produced by index_form_tuple()
> (or all relevant index_form_tuple() callers) is deterministic: for
> every possible heap tuple input there must be a single possible
> (bitwise) output.

That assumption seems unbelievably fragile.  How badly do things
break when it's violated?

Also, is the assumption just that a fixed source tuple will generate
identical index entries across repeated index_form_tuple attempts?
Or is it assuming that logically equal index entries will be bitwise
equal?  The latter is broken on its face, because index_form_tuple()
doesn't try to hide differences in the toasting state of source
datums.

            regards, tom lane


pgsql-hackers by date:

Previous
From: Tomas Vondra
Date:
Subject: Re: COPY FROM WHEN condition
Next
From: Peter Geoghegan
Date:
Subject: Re: Non-deterministic IndexTuple toast compression fromindex_form_tuple() + amcheck false positives