Re: Hybrid Hash/Nested Loop joins and caching results from subplans

From: David Rowley <dgrowleyml(at)gmail(dot)com>
To: PostgreSQL Developers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Cc: Andres Freund <andres(at)anarazel(dot)de>, Andy Fan <zhihui(dot)fan1213(at)gmail(dot)com>, Alvaro Herrera <alvherre(at)alvh(dot)no-ip(dot)org>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Subject: Re: Hybrid Hash/Nested Loop joins and caching results from subplans
Date: 2021-03-29 02:20:36
Message-ID: CAApHDvoOmTtNPoF-+Q1dAOMa8vWFsFbyQb_A0iUKTS5nf2DuLw@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Wed, 24 Mar 2021 at 00:42, David Rowley <dgrowleyml(at)gmail(dot)com> wrote:
> I've now cleaned up the 0001 patch. I ended up changing a few places
> where we pass the RestrictInfo->clause to contain_volatile_functions()
> to instead pass the RestrictInfo itself so that there's a possibility
> of caching the volatility property for a subsequent call.
>
> I also made a pass over the remaining patches and for the 0004 patch,
> aside from the name, "Result Cache", I think that it's ready to go. We
> should consider before RC1 if we should have enable_resultcache switch
> on or off by default.
>
> Does anyone care to have a final look at these patches? I'd like to
> start pushing them fairly soon.

I've now pushed the 0001 patch to cache the volatility of PathTarget
and RestrictInfo.

I'll be looking at the remaining patches over the next few days.

Attached are a rebased set of patches on top of current master. The
only change is to the 0003 patch (was 0004) which had an unstable
regression test for parallel plan with a Result Cache. I've swapped
the unstable test for something that shouldn't fail randomly depending
on if a parallel worker did any work or not.

David

Attachment Content-Type Size
v18-0001-Allow-estimate_num_groups-to-pass-back-further-d.patch text/plain 9.1 KB
v18-0002-Allow-users-of-simplehash.h-to-perform-direct-de.patch text/plain 3.5 KB
v18-0003-Add-Result-Cache-executor-node.patch text/plain 148.9 KB
v18-0004-Remove-code-duplication-in-nodeResultCache.c.patch text/plain 5.1 KB

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message torikoshia 2021-03-29 02:59:13 Re: Get memory contexts of an arbitrary backend process
Previous Message Zhihong Yu 2021-03-29 02:18:17 name of enum used in 'Cache if PathTarget and RestrictInfos contain volatile functions'