pgsql: Further twiddling of nodeHash.c hashtable sizing calculation.

Поиск
Список
Период
Сортировка
От Tom Lane
Тема pgsql: Further twiddling of nodeHash.c hashtable sizing calculation.
Дата
Msg-id E1ZipNb-000517-HR@gemulon.postgresql.org
обсуждение исходный текст
Список pgsql-committers
Further twiddling of nodeHash.c hashtable sizing calculation.

On reflection, the submitted patch didn't really work to prevent the
request size from exceeding MaxAllocSize, because of the fact that we'd
happily round nbuckets up to the next power of 2 after we'd limited it to
max_pointers.  The simplest way to enforce the limit correctly is to
round max_pointers down to a power of 2 when it isn't one already.

(Note that the constraint to INT_MAX / 2, if it were doing anything useful
at all, is properly applied after that.)

Branch
------
master

Details
-------
http://git.postgresql.org/pg/commitdiff/f2fc98fb8e060b2243aba4cfe8b206f54bcc5a4f

Modified Files
--------------
src/backend/executor/nodeHash.c |   11 +++++++++--
1 file changed, 9 insertions(+), 2 deletions(-)


В списке pgsql-committers по дате отправления:

Предыдущее
От: Tom Lane
Дата:
Сообщение: pgsql: Further twiddling of nodeHash.c hashtable sizing calculation.
Следующее
От: Tom Lane
Дата:
Сообщение: pgsql: Further twiddling of nodeHash.c hashtable sizing calculation.