Re: [POC] A better way to expand hash indexes.

Mithun Cy <mithun.cy@enterprisedb.com>

From: Mithun Cy <mithun.cy@enterprisedb.com>
To: Amit Kapila <amit.kapila16@gmail.com>
Cc: David Steele <david@pgmasters.net>, pgsql-hackers <pgsql-hackers@postgresql.org>
Date: 2017-03-25T04:43:00Z
Lists: pgsql-hackers

Attachments

On Tue, Mar 21, 2017 at 8:16 AM, Amit Kapila <amit.kapila16@gmail.com> wrote:
> Sure, I was telling you based on that.  If you are implicitly treating
> it as 2-dimensional array, it might be easier to compute the array
>offsets.

I think calculating spares offset will not become anyway much simpler
we still need to calculate split group and split phase separately. I
have added a patch to show how a 2-dimensional spares code looks like
and where all we need changes.

-- 
Thanks and Regards
Mithun C Y
EnterpriseDB: http://www.enterprisedb.com

Commits

  1. Fix formula in _hash_spareindex.

  2. Expand hash indexes more gradually.

  3. Change hash indexes to store only the hash code rather than the whole indexed