On Fri, Dec 8, 2017 at 5:11 AM, Amit Kapila <amit.kapil...@gmail.com> wrote: >> Okay, I have adjusted the patch accordingly. I have also added a >> regression test which should produce the same result across different >> runs, see if that looks okay to you, then it is better to add such a >> test as well. > > The regression test added by patch needs cleanup at the end which I > have added in the attached patch.
Hmm. If we're going this way, then shouldn't we revert the changes commit 2c09a5c12a66087218c7f8cba269cd3de51b9b82 made to ExecParallelRetrieveInstrumentation? If that function is only ever called once, then there's no point doing InstrInit + InstrAgg node, or checking whether worker_instrument is already initialized. We can just palloc + memcpy as the code did previously. I think. -- Robert Haas EnterpriseDB: http://www.enterprisedb.com The Enterprise PostgreSQL Company