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

Commite78662d

Browse files
committed
optimizer cleanup
1 parentd977ff7 commite78662d

File tree

3 files changed

+14
-12
lines changed

3 files changed

+14
-12
lines changed

‎src/backend/optimizer/geqo/geqo_eval.c

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
*
66
* Copyright (c) 1994, Regents of the University of California
77
*
8-
* $Id: geqo_eval.c,v 1.33 1999/02/16 00:40:59 momjian Exp $
8+
* $Id: geqo_eval.c,v 1.34 1999/02/18 04:55:54 momjian Exp $
99
*
1010
*-------------------------------------------------------------------------
1111
*/
@@ -86,12 +86,12 @@ geqo_eval(Query *root, Gene *tour, int num_gene)
8686
* gimme_tree
8787
* this program presumes that only LEFT-SIDED TREES are considered!
8888
*
89-
* 'outer_rel' is the preceeding join
89+
* 'old_rel' is the preceeding join
9090
*
9191
* Returns a new join relation incorporating all joins in a left-sided tree.
9292
*/
9393
RelOptInfo*
94-
gimme_tree(Query*root,Gene*tour,intrel_count,intnum_gene,RelOptInfo*outer_rel)
94+
gimme_tree(Query*root,Gene*tour,intrel_count,intnum_gene,RelOptInfo*old_rel)
9595
{
9696
RelOptInfo*inner_rel;/* current relation */
9797
intbase_rel_index;
@@ -115,16 +115,16 @@ gimme_tree(Query *root, Gene *tour, int rel_count, int num_gene, RelOptInfo *out
115115
}
116116
else
117117
{/* tree main part */
118-
if (!(new_rels=make_rels_by_clause_joins(root,outer_rel,
118+
if (!(new_rels=make_rels_by_clause_joins(root,old_rel,
119119
inner_rel->joininfo,
120120
inner_rel->relids)))
121121
{
122122
if (!BushyPlanFlag)
123-
new_rels=make_rels_by_clauseless_joins(outer_rel,
123+
new_rels=make_rels_by_clauseless_joins(old_rel,
124124
lcons(inner_rel,NIL));
125125
else
126-
new_rels=make_rels_by_clauseless_joins(outer_rel,
127-
lcons(outer_rel,NIL));
126+
new_rels=make_rels_by_clauseless_joins(old_rel,
127+
lcons(old_rel,NIL));
128128
}
129129

130130
/* process new_rel->pathlist */
@@ -168,7 +168,7 @@ gimme_tree(Query *root, Gene *tour, int rel_count, int num_gene, RelOptInfo *out
168168

169169
}
170170

171-
returnouter_rel;/* tree finished ... */
171+
returnold_rel;/* tree finished ... */
172172
}
173173

174174
staticRelOptInfo*

‎src/backend/optimizer/geqo/geqo_main.c

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
*
77
* Copyright (c) 1994, Regents of the University of California
88
*
9-
* $Id: geqo_main.c,v 1.13 1999/02/13 23:16:08 momjian Exp $
9+
* $Id: geqo_main.c,v 1.14 1999/02/18 04:55:54 momjian Exp $
1010
*
1111
*-------------------------------------------------------------------------
1212
*/
@@ -253,7 +253,8 @@ geqo(Query *root)
253253
best_tour= (Gene*)pool->data[0].string;
254254

255255
/* root->join_relation_list_ will be modified during this ! */
256-
best_rel= (RelOptInfo*)gimme_tree(root,best_tour,0,pool->string_length,NULL);
256+
best_rel= (RelOptInfo*)gimme_tree(root,best_tour,0,
257+
pool->string_length,NULL);
257258

258259
/* DBG: show the query plan
259260
print_plan(best_plan, root);

‎src/include/optimizer/geqo.h

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
*
66
* Copyright (c) 1994, Regents of the University of California
77
*
8-
* $Id: geqo.h,v 1.12 1999/02/15 05:50:02 momjian Exp $
8+
* $Id: geqo.h,v 1.13 1999/02/18 04:55:54 momjian Exp $
99
*
1010
*-------------------------------------------------------------------------
1111
*/
@@ -75,7 +75,8 @@ extern RelOptInfo *geqo(Query *root);
7575
externvoidgeqo_params(intstring_length);
7676

7777
externCostgeqo_eval(Query*root,Gene*tour,intnum_gene);
78-
externRelOptInfo*gimme_tree(Query*root,Gene*tour,intrel_count,intnum_gene,RelOptInfo*outer_rel);
78+
externRelOptInfo*gimme_tree(Query*root,Gene*tour,intrel_count,
79+
intnum_gene,RelOptInfo*old_rel);
7980

8081

8182
#endif/* GEQO_H */

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp