mirror of
https://github.com/postgres/postgres.git
synced 2025-10-27 00:12:01 +03:00
Rethink original decision to use AND/OR Expr nodes to represent bitmap
logic operations during planning. Seems cleaner to create two new Path node types, instead --- this avoids duplication of cost-estimation code. Also, create an enable_bitmapscan GUC parameter to control use of bitmap plans.
This commit is contained in:
@@ -7,7 +7,7 @@
|
||||
* Portions Copyright (c) 1996-2005, PostgreSQL Global Development Group
|
||||
* Portions Copyright (c) 1994, Regents of the University of California
|
||||
*
|
||||
* $PostgreSQL: pgsql/src/include/optimizer/cost.h,v 1.65 2005/04/21 02:28:02 tgl Exp $
|
||||
* $PostgreSQL: pgsql/src/include/optimizer/cost.h,v 1.66 2005/04/21 19:18:13 tgl Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@@ -42,6 +42,7 @@ extern double cpu_operator_cost;
|
||||
extern Cost disable_cost;
|
||||
extern bool enable_seqscan;
|
||||
extern bool enable_indexscan;
|
||||
extern bool enable_bitmapscan;
|
||||
extern bool enable_tidscan;
|
||||
extern bool enable_sort;
|
||||
extern bool enable_hashagg;
|
||||
@@ -53,8 +54,10 @@ extern double clamp_row_est(double nrows);
|
||||
extern void cost_seqscan(Path *path, Query *root, RelOptInfo *baserel);
|
||||
extern void cost_index(IndexPath *path, Query *root, IndexOptInfo *index,
|
||||
List *indexQuals, bool is_injoin);
|
||||
extern void cost_bitmap_scan(Path *path, Query *root, RelOptInfo *baserel,
|
||||
Node *bitmapqual, bool is_injoin);
|
||||
extern void cost_bitmap_heap_scan(Path *path, Query *root, RelOptInfo *baserel,
|
||||
Path *bitmapqual, bool is_injoin);
|
||||
extern void cost_bitmap_and_node(BitmapAndPath *path, Query *root);
|
||||
extern void cost_bitmap_or_node(BitmapOrPath *path, Query *root);
|
||||
extern void cost_tidscan(Path *path, Query *root,
|
||||
RelOptInfo *baserel, List *tideval);
|
||||
extern void cost_subqueryscan(Path *path, RelOptInfo *baserel);
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
* Portions Copyright (c) 1996-2005, PostgreSQL Global Development Group
|
||||
* Portions Copyright (c) 1994, Regents of the University of California
|
||||
*
|
||||
* $PostgreSQL: pgsql/src/include/optimizer/pathnode.h,v 1.58 2005/04/19 22:35:18 tgl Exp $
|
||||
* $PostgreSQL: pgsql/src/include/optimizer/pathnode.h,v 1.59 2005/04/21 19:18:13 tgl Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@@ -35,7 +35,13 @@ extern IndexPath *create_index_path(Query *root,
|
||||
ScanDirection indexscandir);
|
||||
extern BitmapHeapPath *create_bitmap_heap_path(Query *root,
|
||||
RelOptInfo *rel,
|
||||
Node *bitmapqual);
|
||||
Path *bitmapqual);
|
||||
extern BitmapAndPath *create_bitmap_and_path(Query *root,
|
||||
RelOptInfo *rel,
|
||||
List *bitmapquals);
|
||||
extern BitmapOrPath *create_bitmap_or_path(Query *root,
|
||||
RelOptInfo *rel,
|
||||
List *bitmapquals);
|
||||
extern TidPath *create_tidscan_path(Query *root, RelOptInfo *rel,
|
||||
List *tideval);
|
||||
extern AppendPath *create_append_path(RelOptInfo *rel, List *subpaths);
|
||||
|
||||
Reference in New Issue
Block a user