Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit297daa9

Browse files
committed
Refactor and cleanup runtime partition prune code a little
* Move the execution pruning initialization steps that are commonbetween both ExecInitAppend() and ExecInitMergeAppend() into a newfunction ExecInitPartitionPruning() defined in execPartition.c.Those steps include creation of a PartitionPruneState to be used forall instances of pruning and determining the minimal set of childsubplans that need to be initialized by performing initial pruning ifneeded, and finally adjusting the subplan_map arrays in thePartitionPruneState to reflect the new set of subplans remainingafter initial pruning if it was indeed performed.ExecCreatePartitionPruneState() is no longer exported out ofexecPartition.c and has been renamed to CreatePartitionPruneState()as a local sub-routine of ExecInitPartitionPruning().* Likewise, ExecFindInitialMatchingSubPlans() that was in charge ofperforming initial pruning no longer needs to be exported. In fact,since it would now have the same body as the more generally namedExecFindMatchingSubPlans(), except differing in the value ofinitial_prune passed to the common subroutinefind_matching_subplans_recurse(), it seems better to remove it and addan initial_prune argument to ExecFindMatchingSubPlans().* Add an ExprContext field to PartitionPruneContext to remove theimplicit assumption in the runtime pruning code that the ExprContext touse to compute pruning expressions that need one can always rely on thePlanState providing it. A future patch will allow runtime pruning (atleast the initial pruning steps) to be performed without thecorresponding PlanState yet having been created, so this will help.Author: Amit Langote <amitlangote09@gmail.com>Discussion:https://postgr.es/m/CA+HiwqEYCpEqh2LMDOp9mT+4-QoVe8HgFMKBjntEMCTZLpcCCA@mail.gmail.com
1 parent7a43a1f commit297daa9

File tree

6 files changed

+298
-293
lines changed

6 files changed

+298
-293
lines changed

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp