Re: pgsql: Avoid creation of the free space map for small heap relations, t

Tom Lane <tgl@sss.pgh.pa.us>

From: Tom Lane <tgl@sss.pgh.pa.us>
To: Amit Kapila <akapila@postgresql.org>
Cc: pgsql-hackers@lists.postgresql.org
Date: 2019-02-25T17:44:28Z
Lists: pgsql-hackers
I wrote:
> Amit Kapila <akapila@postgresql.org> writes:
>> Avoid creation of the free space map for small heap relations, take 2.

> I think this patch still has some issues.

Just out of curiosity ... how can it possibly be even a little bit sane
that fsm_local_map is a single static data structure, without even any
indication of which table it is for?

If, somehow, there's a rational argument for that design, why is it
not explained in freespace.c?  The most charitable interpretation of
what I see there is that it's fatally undercommented.

			regards, tom lane


Commits

  1. Clear the local map when not used.

  2. Remove unneeded argument from _bt_getstackbuf().

  3. Avoid creation of the free space map for small heap relations, take 2.