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

Commit5b804cc

Browse files
committed
Fix costing of parallel hash joins.
Commit1804284 established that single-batchparallel-aware hash joins could create one large shared hash table using thecombined work_mem budget of all participants. The costing accidentallyassumed that parallel-oblivious hash joins could also do that. Thedocumentation for initial_cost_hashjoin() also failed to mention the newargument. Repair.Author: Thomas MunroReported-By: Antonin HouskaReviewed-By: Antonin HouskaDiscussion:https://postgr.es/m/12441.1513935950%40localhost
1 parenta3739e3 commit5b804cc

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

‎src/backend/optimizer/path/costsize.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3143,6 +3143,8 @@ cached_scansel(PlannerInfo *root, RestrictInfo *rinfo, PathKey *pathkey)
31433143
* 'outer_path' is the outer input to the join
31443144
* 'inner_path' is the inner input to the join
31453145
* 'extra' contains miscellaneous information about the join
3146+
* 'parallel_hash' indicates that inner_path is partial and that a shared
3147+
*hash table will be built in parallel
31463148
*/
31473149
void
31483150
initial_cost_hashjoin(PlannerInfo*root,JoinCostWorkspace*workspace,

‎src/backend/optimizer/path/joinpath.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -814,7 +814,7 @@ try_partial_hashjoin_path(PlannerInfo *root,
814814
* cost. Bail out right away if it looks terrible.
815815
*/
816816
initial_cost_hashjoin(root,&workspace,jointype,hashclauses,
817-
outer_path,inner_path,extra,true);
817+
outer_path,inner_path,extra,parallel_hash);
818818
if (!add_partial_path_precheck(joinrel,workspace.total_cost,NIL))
819819
return;
820820

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp