pgsql: Fix GIN data page split ratio calculation.

Поиск
Список
Период
Сортировка
От Heikki Linnakangas
Тема pgsql: Fix GIN data page split ratio calculation.
Дата
Msg-id E1XSMNj-0004SI-Gg@gemulon.postgresql.org
обсуждение исходный текст
Список pgsql-committers
Fix GIN data page split ratio calculation.

The code that tried to split a page at 75/25 ratio, when appending to the
end of an index, was buggy in two ways. First, there was a silly typo that
caused it to just fill the left page as full as possible. But the logic as
it was intended wasn't correct either, and would actually have given a ratio
closer to 60/40 than 75/25.

Gaetano Mendola spotted the typo. Backpatch to 9.4, where this code was added.

Branch
------
REL9_4_STABLE

Details
-------
http://git.postgresql.org/pg/commitdiff/79ee6370ee803b36c2649cfb7655affa2c1007f1

Modified Files
--------------
src/backend/access/gin/gindatapage.c |   29 +++++++++++++++++------------
1 file changed, 17 insertions(+), 12 deletions(-)


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

Предыдущее
От: Tom Lane
Дата:
Сообщение: pgsql: Fix power_var_int() for large integer exponents.
Следующее
От: Heikki Linnakangas
Дата:
Сообщение: pgsql: Fix GIN data page split ratio calculation.