Re: Fix generate_useful_gather_paths for parallel unsafe pathkeys

Tomas Vondra <tomas.vondra@enterprisedb.com>

From: Tomas Vondra <tomas.vondra@enterprisedb.com>
To: James Coleman <jtc331@gmail.com>
Cc: pgsql-hackers <pgsql-hackers@postgresql.org>, luis.roberto@siscobra.com.br, Tom Lane <tgl@sss.pgh.pa.us>, Robert Haas <robertmhaas@gmail.com>
Date: 2020-12-22T01:07:09Z
Lists: pgsql-hackers
Hi,

I've pushed (and backpatched) all the fixes posted to this thread. I 
believe that covers all the incremental sort fixes, so I've marked [1] 
as committed.

[1] https://commitfest.postgresql.org/31/2754/


regards

-- 
Tomas Vondra
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company



Commits

  1. Improve find_em_expr_usable_for_sorting_rel comment

  2. Don't search for volatile expr in find_em_expr_usable_for_sorting_rel

  3. Disallow SRFs when considering sorts below Gather Merge

  4. Check parallel safety in generate_useful_gather_paths

  5. Consider unsorted paths in generate_useful_gather_paths

  6. Error out when Gather Merge input is not sorted