Re: MinIndexTupleSize seems slightly wrong - Mailing list pgsql-hackers

From Peter Geoghegan
Subject Re: MinIndexTupleSize seems slightly wrong
Date
Msg-id CAH2-Wz=kGa3pQbG1nbuvL0htKA7=u2=XBdBzPTVsOrB8xHLBQA@mail.gmail.com
Whole thread Raw
In response to Re: MinIndexTupleSize seems slightly wrong  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
On Fri, Apr 13, 2018 at 10:45 AM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
> As long as btree only has one no-data tuple per page, I think we are good,
> because this calculation does not account for page special space.  We might
> be underestimating how many tuples can fit by one MAXALIGN quantum, but
> the special space takes up at least one MAXALIGN quantum, so it's safe.
>
> Twouldn't be a bad idea to document this reasoning, though.

Thanks for taking care of this.

> Also, my first reaction on looking at this code was "who added
> MinIndexTupleSize and then didn't replace the equivalent subexpression
> of MaxIndexTuplesPerPage with MinIndexTupleSize?".

I had the same reaction.

-- 
Peter Geoghegan


pgsql-hackers by date:

Previous
From: David Arnold
Date:
Subject: Re: Proposal: Adding json logging
Next
From: David Arnold
Date:
Subject: Re: Proposal: Adding json logging