From: Tom Lane <tgl@sss.pgh.pa.us>
To: pgsql-hackers@lists.postgresql.org
Subject: Parallel append plan instability/randomness
Date: Sat, 06 Jan 2018 19:14:43 -0500
Message-ID: <7752.1515284083@sss.pgh.pa.us> (raw)
According to buildfarm member silverfish,
https://buildfarm.postgresql.org/cgi-bin/show_log.pl?nm=silverfish&dt=2018-01-06%2008%3A53%3A38
it's possible to sometimes get this failure in the regression tests:
inline patch 1: /mnt/buildfarm/buildroot/HEAD/pgsql.build/src/test/regress/results/select_parallel.out (+1/-1 lines) download inline-1.patch*** /mnt/buildfarm/buildroot/HEAD/pgsql.build/../pgsql/src/test/regress/expected/select_parallel.out Tue Dec 19 20:24:02 2017
--- /mnt/buildfarm/buildroot/HEAD/pgsql.build/src/test/regress/results/select_parallel.out Sat Jan 6 09:21:39 2018
***************
*** 75,84 ****
Workers Planned: 3
-> Partial Aggregate
-> Parallel Append
-> Seq Scan on d_star
-> Seq Scan on f_star
-> Seq Scan on e_star
- -> Seq Scan on b_star
-> Seq Scan on c_star
-> Seq Scan on a_star
(11 rows)
--- 75,84 ----
Workers Planned: 3
-> Partial Aggregate
-> Parallel Append
+ -> Seq Scan on b_star
-> Seq Scan on d_star
-> Seq Scan on f_star
-> Seq Scan on e_star
-> Seq Scan on c_star
-> Seq Scan on a_star
(11 rows)
Irreproducible failures in the regression tests are not very acceptable.
Furthermore, considering that the query being tested is
explain (costs off)
select round(avg(aa)), sum(aa) from a_star;
it seems to me that the "expected" order of the sub-scans is mighty
random to begin with. A non-parallel implementation of the same
query will consistently scan these tables in their inheritance order:
Aggregate
-> Append
-> Seq Scan on a_star
-> Seq Scan on b_star
-> Seq Scan on c_star
-> Seq Scan on d_star
-> Seq Scan on e_star
-> Seq Scan on f_star
Could we fix the parallel case to behave similarly please?
regards, tom lane
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-hackers@postgresql.org
Cc: tgl@sss.pgh.pa.us, pgsql-hackers@lists.postgresql.org
Subject: Re: Parallel append plan instability/randomness
In-Reply-To: <7752.1515284083@sss.pgh.pa.us>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox