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

Appearance settings

Commit 9d00cf4

Browse filesBrowse files
committed
Remove some redundant set_cheapest() calls.
Commit e2fa76d centralized the responsibility for doing set_cheapest() for a baserel, but these functions added later seemingly didn't get the memo. There's no apparent reason why we need the cheapest path for these relation types to be available any sooner than it is for other base relation types, so delete the duplicate calls. Doesn't save much since there's only one path in these cases, but it might improve clarity. Richard Guo Discussion: https://postgr.es/m/CAMbWs4-KFEU_fDuJPNCOkUu3rwvZvKBEytkd9VrM4kH4-2h1CQ@mail.gmail.com
1 parent d365ae7 commit 9d00cf4
Copy full SHA for 9d00cf4

File tree

Expand file treeCollapse file tree

1 file changed

+0
-6
lines changed
Filter options
Expand file treeCollapse file tree

1 file changed

+0
-6
lines changed

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

Copy file name to clipboardExpand all lines: src/backend/optimizer/path/allpaths.c
-6Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2966,9 +2966,6 @@ set_namedtuplestore_pathlist(PlannerInfo *root, RelOptInfo *rel,
29662966

29672967
/* Generate appropriate path */
29682968
add_path(rel, create_namedtuplestorescan_path(root, rel, required_outer));
2969-
2970-
/* Select cheapest path (pretty easy in this case...) */
2971-
set_cheapest(rel);
29722969
}
29732970

29742971
/*
@@ -2996,9 +2993,6 @@ set_result_pathlist(PlannerInfo *root, RelOptInfo *rel,
29962993

29972994
/* Generate appropriate path */
29982995
add_path(rel, create_resultscan_path(root, rel, required_outer));
2999-
3000-
/* Select cheapest path (pretty easy in this case...) */
3001-
set_cheapest(rel);
30022996
}
30032997

30042998
/*

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.