mirror of
https://github.com/postgres/postgres.git
synced 2025-07-18 17:42:25 +03:00
Don't generate parallel paths for rels with parallel-restricted outputs.
Such paths are unsafe. To make it cheaper to detect when this case applies, track whether a relation's default PathTarget contains any non-Vars. In most cases, the answer will be no, which enables us to determine cheaply that the target list for a proposed path is parallel-safe. However, subquery pull-up can create cases that require us to inspect the target list more carefully. Amit Kapila, reviewed by me.
This commit is contained in:
@ -2083,6 +2083,7 @@ _outRelOptInfo(StringInfo str, const RelOptInfo *node)
|
||||
WRITE_BOOL_FIELD(consider_param_startup);
|
||||
WRITE_BOOL_FIELD(consider_parallel);
|
||||
WRITE_NODE_FIELD(reltarget);
|
||||
WRITE_BOOL_FIELD(reltarget_has_non_vars);
|
||||
WRITE_NODE_FIELD(pathlist);
|
||||
WRITE_NODE_FIELD(ppilist);
|
||||
WRITE_NODE_FIELD(partial_pathlist);
|
||||
|
Reference in New Issue
Block a user