mirror of
https://github.com/postgres/postgres.git
synced 2025-06-23 14:01:44 +03:00
Get rid of old version of BuildTupleHashTable().
It was reasonable to preserve the old API of BuildTupleHashTable() in the back branches, but in HEAD we should actively discourage use of that version. There are no remaining callers in core, so just get rid of it. Then rename BuildTupleHashTableExt() back to BuildTupleHashTable(). While at it, fix up the miserably-poorly-maintained header comment for BuildTupleHashTable[Ext]. It looks like more than one patch in this area has had the opinion that updating comments is beneath them. Discussion: https://postgr.es/m/538343.1734646986@sss.pgh.pa.us
This commit is contained in:
@ -523,7 +523,7 @@ buildSubPlanHash(SubPlanState *node, ExprContext *econtext)
|
||||
* Because the input slot for each hash table is always the slot resulting
|
||||
* from an ExecProject(), we can use TTSOpsVirtual for the input ops. This
|
||||
* saves a needless fetch inner op step for the hashing ExprState created
|
||||
* in BuildTupleHashTableExt().
|
||||
* in BuildTupleHashTable().
|
||||
*/
|
||||
MemoryContextReset(node->hashtablecxt);
|
||||
node->havehashrows = false;
|
||||
@ -536,20 +536,20 @@ buildSubPlanHash(SubPlanState *node, ExprContext *econtext)
|
||||
if (node->hashtable)
|
||||
ResetTupleHashTable(node->hashtable);
|
||||
else
|
||||
node->hashtable = BuildTupleHashTableExt(node->parent,
|
||||
node->descRight,
|
||||
&TTSOpsVirtual,
|
||||
ncols,
|
||||
node->keyColIdx,
|
||||
node->tab_eq_funcoids,
|
||||
node->tab_hash_funcs,
|
||||
node->tab_collations,
|
||||
nbuckets,
|
||||
0,
|
||||
node->planstate->state->es_query_cxt,
|
||||
node->hashtablecxt,
|
||||
node->hashtempcxt,
|
||||
false);
|
||||
node->hashtable = BuildTupleHashTable(node->parent,
|
||||
node->descRight,
|
||||
&TTSOpsVirtual,
|
||||
ncols,
|
||||
node->keyColIdx,
|
||||
node->tab_eq_funcoids,
|
||||
node->tab_hash_funcs,
|
||||
node->tab_collations,
|
||||
nbuckets,
|
||||
0,
|
||||
node->planstate->state->es_query_cxt,
|
||||
node->hashtablecxt,
|
||||
node->hashtempcxt,
|
||||
false);
|
||||
|
||||
if (!subplan->unknownEqFalse)
|
||||
{
|
||||
@ -565,20 +565,20 @@ buildSubPlanHash(SubPlanState *node, ExprContext *econtext)
|
||||
if (node->hashnulls)
|
||||
ResetTupleHashTable(node->hashnulls);
|
||||
else
|
||||
node->hashnulls = BuildTupleHashTableExt(node->parent,
|
||||
node->descRight,
|
||||
&TTSOpsVirtual,
|
||||
ncols,
|
||||
node->keyColIdx,
|
||||
node->tab_eq_funcoids,
|
||||
node->tab_hash_funcs,
|
||||
node->tab_collations,
|
||||
nbuckets,
|
||||
0,
|
||||
node->planstate->state->es_query_cxt,
|
||||
node->hashtablecxt,
|
||||
node->hashtempcxt,
|
||||
false);
|
||||
node->hashnulls = BuildTupleHashTable(node->parent,
|
||||
node->descRight,
|
||||
&TTSOpsVirtual,
|
||||
ncols,
|
||||
node->keyColIdx,
|
||||
node->tab_eq_funcoids,
|
||||
node->tab_hash_funcs,
|
||||
node->tab_collations,
|
||||
nbuckets,
|
||||
0,
|
||||
node->planstate->state->es_query_cxt,
|
||||
node->hashtablecxt,
|
||||
node->hashtempcxt,
|
||||
false);
|
||||
}
|
||||
else
|
||||
node->hashnulls = NULL;
|
||||
|
Reference in New Issue
Block a user