summaryrefslogtreecommitdiff
path: root/src/include
diff options
context:
space:
mode:
authorTom Lane2008-11-13 17:42:10 +0000
committerTom Lane2008-11-13 17:42:10 +0000
commit10e3acb8e7bd3298ba2b942f86c18f5ba2e142a8 (patch)
tree19bf64481b48aa0f21669a994958fb7c4be2645f /src/include
parent3379fae6de5994b242cedfa48cf613ecfee3db24 (diff)
Prevent synchronous scan during GIN index build, because GIN is optimized
for inserting tuples in increasing TID order. It's not clear whether this fully explains Ivan Sergio Borgonovo's complaint, but simple testing confirms that a scan that doesn't start at block 0 can slow GIN build by a factor of three or four. Backpatch to 8.3. Sync scan didn't exist before that.
Diffstat (limited to 'src/include')
-rw-r--r--src/include/catalog/index.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/include/catalog/index.h b/src/include/catalog/index.h
index a5ab195c233..939c47cd916 100644
--- a/src/include/catalog/index.h
+++ b/src/include/catalog/index.h
@@ -7,7 +7,7 @@
* Portions Copyright (c) 1996-2008, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
- * $PostgreSQL: pgsql/src/include/catalog/index.h,v 1.75 2008/01/01 19:45:56 momjian Exp $
+ * $PostgreSQL: pgsql/src/include/catalog/index.h,v 1.76 2008/11/13 17:42:10 tgl Exp $
*
*-------------------------------------------------------------------------
*/
@@ -63,6 +63,7 @@ extern void index_build(Relation heapRelation,
extern double IndexBuildHeapScan(Relation heapRelation,
Relation indexRelation,
IndexInfo *indexInfo,
+ bool allow_sync,
IndexBuildCallback callback,
void *callback_state);