aboutsummaryrefslogtreecommitdiff
path: root/src/backend/executor/nodeSubplan.c
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2003-08-19 01:13:41 +0000
committerTom Lane <tgl@sss.pgh.pa.us>2003-08-19 01:13:41 +0000
commit80860c32d92fe3445dcb7de70091354c9d0406b0 (patch)
tree2119ed51447a2c45fc75dab13e8ec89115a9890a /src/backend/executor/nodeSubplan.c
parent23e10843db588928e18bd58018c2e70f4548f177 (diff)
downloadpostgresql-80860c32d92fe3445dcb7de70091354c9d0406b0.tar.gz
postgresql-80860c32d92fe3445dcb7de70091354c9d0406b0.zip
Improve dynahash.c's API so that caller can specify the comparison function
as well as the hash function (formerly the comparison function was hardwired as memcmp()). This makes it possible to eliminate the special-purpose hashtable management code in execGrouping.c in favor of using dynahash to manage tuple hashtables; which is a win because dynahash knows how to expand a hashtable when the original size estimate was too small, whereas the special-purpose code was too stupid to do that. (See recent gripe from Stephan Szabo about poor performance when hash table size estimate is way off.) Free side benefit: when using string_hash, the default comparison function is now strncmp() instead of memcmp(). This should eliminate some part of the overhead associated with larger NAMEDATALEN values.
Diffstat (limited to 'src/backend/executor/nodeSubplan.c')
-rw-r--r--src/backend/executor/nodeSubplan.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/backend/executor/nodeSubplan.c b/src/backend/executor/nodeSubplan.c
index 7530be263f3..23b0cd3bf3d 100644
--- a/src/backend/executor/nodeSubplan.c
+++ b/src/backend/executor/nodeSubplan.c
@@ -7,7 +7,7 @@
* Portions Copyright (c) 1994, Regents of the University of California
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/executor/nodeSubplan.c,v 1.54 2003/08/08 21:41:42 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/executor/nodeSubplan.c,v 1.55 2003/08/19 01:13:40 tgl Exp $
*
*-------------------------------------------------------------------------
*/
@@ -627,8 +627,8 @@ findPartialMatch(TupleHashTable hashtable, TupleTableSlot *slot)
TupleHashIterator hashiter;
TupleHashEntry entry;
- ResetTupleHashIterator(&hashiter);
- while ((entry = ScanTupleHashTable(hashtable, &hashiter)) != NULL)
+ ResetTupleHashIterator(hashtable, &hashiter);
+ while ((entry = ScanTupleHashTable(&hashiter)) != NULL)
{
if (!execTuplesUnequal(entry->firstTuple,
tuple,