Re: pgsql: Add parallel-aware hash joins.

From: Thomas Munro <thomas(dot)munro(at)enterprisedb(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Andres Freund <andres(at)anarazel(dot)de>, pgsql-committers <pgsql-committers(at)postgresql(dot)org>
Subject: Re: pgsql: Add parallel-aware hash joins.
Date: 2017-12-30 13:51:26
Message-ID: CAEepm=3GL7H3vxQb0LTJ9KnKhpnvaqOK=yn9p-O8zyjxRgXntA@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers pgsql-hackers

On Fri, Dec 29, 2017 at 2:21 AM, Thomas Munro
<thomas(dot)munro(at)enterprisedb(dot)com> wrote:
> On Thu, Dec 28, 2017 at 5:15 PM, Thomas Munro
> <thomas(dot)munro(at)enterprisedb(dot)com> wrote:
>> On Thu, Dec 28, 2017 at 3:32 PM, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
>>> ! Buckets: 1024 (originally 2048) Batches: 1 (originally 1) Memory Usage: 0kB
>>> ! Execution time: 243.120 ms
>>>
>>> I don't have enough insight to be totally sure what this means, but the
>>> "Memory Usage: 0kB" bit is obviously bogus, so I'd venture that at least
>>> part of the issue is failure to return stats from a worker.
>>
>> Hmm. Yeah, that seems quite likely -- thanks. Investigating now.
>
> This is explained by the early exit case in
> ExecParallelHashEnsureBatchAccessors(). With just the right timing,
> it finishes up not reporting the true nbatch number, and never calling
> ExecParallelHashUpdateSpacePeak().

Hi Tom,

You mentioned that prairiedog sees the problem about one time in
thirty. Would you mind checking if it goes away with this patch
applied?

--
Thomas Munro
http://www.enterprisedb.com

Attachment Content-Type Size
fix-phj-explain.patch application/octet-stream 8.4 KB

In response to

Responses

Browse pgsql-committers by date

  From Date Subject
Next Message Andres Freund 2017-12-30 16:16:34 Re: pgsql: Add parallel-aware hash joins.
Previous Message Alvaro Herrera 2017-12-29 21:36:45 pgsql: Fix typo

Browse pgsql-hackers by date

  From Date Subject
Next Message Dave Cramer 2017-12-30 14:07:02 What does Time.MAX_VALUE actually represent?
Previous Message Michael Paquier 2017-12-30 13:08:22 Re: [HACKERS] taking stdbool.h into use