Re: Binary search in ScalarArrayOpExpr for OR'd constant arrays

From: James Coleman <jtc331(at)gmail(dot)com>
To: Tomas Vondra <tomas(dot)vondra(at)2ndquadrant(dot)com>
Cc: David Rowley <dgrowleyml(at)gmail(dot)com>, pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Binary search in ScalarArrayOpExpr for OR'd constant arrays
Date: 2020-05-01 02:20:39
Message-ID: CAAaqYe8LZxnfxsKN0kfsoUnxREayAzpo+ZxtHijLU6T4==Uewg@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Tue, Apr 28, 2020 at 8:25 AM Tomas Vondra
<tomas(dot)vondra(at)2ndquadrant(dot)com> wrote:
...
> Any particular reasons to pick dynahash over simplehash? ISTM we're
> using simplehash elsewhere in the executor (grouping, tidbitmap, ...),
> while there are not many places using dynahash for simple short-lived
> hash tables. Of course, that alone is a weak reason to insist on using
> simplehash here, but I suppose there were reasons for not using dynahash
> and we'll end up facing the same issues here.

I've attached a patch series that includes switching to simplehash.
Obviously we'd really just collapse all of these patches, but it's
perhaps interesting to see the changes required to use each style
(binary search, dynahash, simplehash).

As before, there are clearly comments and naming things to be
addressed, but the implementation should be reasonably clean.

James

Attachment Content-Type Size
v3-0003-Try-simple-hash.patch text/x-patch 12.1 KB
v3-0002-Try-using-dynahash.patch text/x-patch 13.8 KB
v3-0001-Binary-search-const-arrays-in-OR-d-ScalarArrayOps.patch text/x-patch 15.6 KB

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Fujii Masao 2020-05-01 02:49:51 Re: SLRU statistics
Previous Message James Coleman 2020-05-01 01:53:10 Comment simplehash/dynahash trade-offs