Remove HASH_DIRSIZE, always use the default algorithm to select it
Heikki Linnakangas <heikki.linnakangas@iki.fi>
Author:
Heikki Linnakangas <heikki.linnakangas@iki.fi>
Date: 2026-04-03T23:40:28Z
Releases:
19 (unreleased)
Remove HASH_DIRSIZE, always use the default algorithm to select it It's not very useful to specify a non-standard directory size. The HASH_DIRSIZE option was only used for shared memory hash tables, and those always used hash_select_dirsize() to choose the size, which in turn just uses the default algorithm anyway. That assumption was ingrained in hash_estimate_size(), too. Reviewed-by: Tomas Vondra <tomas@vondra.me> Discussion: https://www.postgresql.org/message-id/01ab1d41-3eda-4705-8bbd-af898f5007f1@iki.fi
Files
| Path | Change | +/− |
|---|---|---|
| src/backend/storage/ipc/shmem.c | modified | +1 −2 |
| src/backend/utils/hash/dynahash.c | modified | +13 −50 |
| src/include/utils/hsearch.h | modified | +1 −5 |
Discussion
- Shared hash table allocations 16 messages · 2026-03-27 → 2026-04-03