Skip to content

Commit

Permalink
remove: custom_path_remember() infrastructure
Browse files Browse the repository at this point in the history
It was reported at heterodb#618.
When # of relations involved in a join exceeds the threshold of GEQO,
PostgreSQL switches optimization logic from the default one.
GEOQ internally uses its own memory context, thus, plan-nodes are
eventually released at end of the GEOQ optimization routine.
It makes impossible to track unused path-nodes, so we changed the
logic to merge joins with multiple-relations.
  • Loading branch information
kaigai committed Jul 27, 2023
1 parent db5d301 commit 11587e7
Show file tree
Hide file tree
Showing 7 changed files with 594 additions and 527 deletions.
2 changes: 1 addition & 1 deletion src/dpu_join.c
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@

/* static variables */
static set_join_pathlist_hook_type set_join_pathlist_next = NULL;
static CustomPathMethods dpujoin_path_methods;
CustomPathMethods dpujoin_path_methods;
static CustomScanMethods dpujoin_plan_methods;
static CustomExecMethods dpujoin_exec_methods;
bool pgstrom_enable_dpujoin; /* GUC */
Expand Down
9 changes: 3 additions & 6 deletions src/dpu_scan.c
Original file line number Diff line number Diff line change
Expand Up @@ -46,15 +46,12 @@ DpuScanAddScanPath(PlannerInfo *root,

cpath = buildXpuScanPath(root,
baserel,
TASK_KIND__DPUSCAN,
(try_parallel > 0),
true, /* allow host quals */
false, /* disallow no device quals */
TASK_KIND__DPUSCAN);
if (cpath && custom_path_remember(root,
baserel,
(try_parallel > 0),
TASK_KIND__DPUSCAN,
cpath))
&dpuscan_path_methods);
if (cpath)
{
if (try_parallel == 0)
add_path(baserel, &cpath->path);
Expand Down
Loading

0 comments on commit 11587e7

Please sign in to comment.