Re: pgsql: Add parallel-aware hash joins.

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

From: Tom Lane <tgl@sss.pgh.pa.us>
To: Thomas Munro <thomas.munro@enterprisedb.com>
Cc: Andres Freund <andres@anarazel.de>, pgsql-committers <pgsql-committers@postgresql.org>
Date: 2018-01-22T15:01:50Z
Lists: pgsql-hackers
Thomas Munro <thomas.munro@enterprisedb.com> writes:
> On Mon, Jan 22, 2018 at 11:17 PM, Thomas Munro
> <thomas.munro@enterprisedb.com> wrote:
>> It looks to me like longfin's average and
>> variation increased half way between fa330f9a and 18042840, somewhere
>> near Dec 7 to 9, when we went from ~40s +/- 1 to ~50s with several
>> seconds' variation.  Was there some other environmental change then on
>> that machine?

> Ahh.  That corresponds to the release of this patch:
> https://support.apple.com/en-nz/HT208331

Yeah, I'm pretty sure that I installed that update immediately when
it came out.

There were some other strange things going on on that machine too;
I remember having noticed and killed a daemon process that seemed to be
stuck at 100% CPU.  That might explain the sudden dropoff in runtimes in
early January.  And seeing that the times seem to be back up, I looked
just now, and there it is again:

PID    COMMAND      %CPU TIME     #TH   #WQ  #PORT MEM    PURG   CMPRS  PGRP
360    fontworker   75.9 238 hrs  4     4    45-   28M    0B     0B     360
359    fontd        25.3 86:18:50 4/1   3/1  74    33M+   0B     1396K  359
76     logd         12.7 26:25:16 5     5    611   31M-   0B     0B     76
46241  top          2.6  00:01.04 1/1   0    23    2140K  0B     0B     46241

Weird --- my other macOS machines aren't doing that.

Anyway, it looks like we should write off these longfin timings as
ambient noise :-(

			regards, tom lane


Commits

  1. Update obsolete sentence in README.parallel.

  2. Rewrite ConditionVariableBroadcast() to avoid live-lock.

  3. Tweak parallel hash join test case in hopes of improving stability.

  4. Rename pg_rewind's copy_file_range() to avoid conflict with new linux syscall.

  5. Fix some minor errors in new PHJ code.

  6. Fix EXPLAIN ANALYZE output for Parallel Hash.

  7. Fix rare assertion failure in parallel hash join.

  8. Cancel CV sleep during subtransaction abort.

  9. Add parallel-aware hash joins.

  10. Fix EXPLAIN ANALYZE of hash join when the leader doesn't participate.

  11. Add some regression tests that exercise hash join code.