Skip to content

Commit ea43da5

Browse files
committed
Use hash table name, not one-size-fits-all 'DynaHashTable', to identify
memory contexts belonging to hash tables. Makes the memory stats printout a little more useful.
1 parent 5c5b911 commit ea43da5

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/backend/utils/hash/dynahash.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
*
1010
*
1111
* IDENTIFICATION
12-
* $PostgreSQL: pgsql/src/backend/utils/hash/dynahash.c,v 1.49 2003/11/29 19:52:01 pgsql Exp $
12+
* $PostgreSQL: pgsql/src/backend/utils/hash/dynahash.c,v 1.50 2003/12/29 23:54:22 tgl Exp $
1313
*
1414
*-------------------------------------------------------------------------
1515
*/
@@ -148,7 +148,7 @@ hash_create(const char *tabname, long nelem, HASHCTL *info, int flags)
148148
{
149149
/*
150150
* ctl structure is preallocated for shared memory tables. Note
151-
* that HASH_DIRSIZE had better be set as well.
151+
* that HASH_DIRSIZE and HASH_ALLOC had better be set as well.
152152
*/
153153
hashp->hctl = info->hctl;
154154
hashp->dir = info->dir;
@@ -220,7 +220,7 @@ hash_create(const char *tabname, long nelem, HASHCTL *info, int flags)
220220
{
221221
/* remaining hash table structures live in child of given context */
222222
hashp->hcxt = AllocSetContextCreate(CurrentDynaHashCxt,
223-
"DynaHashTable",
223+
tabname,
224224
ALLOCSET_DEFAULT_MINSIZE,
225225
ALLOCSET_DEFAULT_INITSIZE,
226226
ALLOCSET_DEFAULT_MAXSIZE);

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy