Re: Lowering the ever-growing heap->pd_lower

Поиск
Список
Период
Сортировка
От Andres Freund
Тема Re: Lowering the ever-growing heap->pd_lower
Дата
Msg-id 20220408211815.jac65f5qlmu43sjj@alap3.anarazel.de
обсуждение исходный текст
Ответ на Re: Lowering the ever-growing heap->pd_lower  (Robert Haas <robertmhaas@gmail.com>)
Ответы Re: Lowering the ever-growing heap->pd_lower  (Peter Geoghegan <pg@bowt.ie>)
Список pgsql-hackers
Hi,

On 2022-04-08 15:04:37 -0400, Robert Haas wrote:
> I meant wasting space in the page. I think that's a real concern.
> Imagine you allowed 1000 line pointers per page. Each one consumes 2
> bytes.

It's 4 bytes per line pointer, right?

struct ItemIdData {
        unsigned int               lp_off:15;            /*     0: 0  4 */
        unsigned int               lp_flags:2;           /*     0:15  4 */
        unsigned int               lp_len:15;            /*     0:17  4 */

        /* size: 4, cachelines: 1, members: 3 */
        /* last cacheline: 4 bytes */
};

Or am I confusing myself somehow?


I do wish the length of the tuple weren't in ItemIdData, but part of the
tuple, so we'd not waste this space for dead items (I think it'd also simplify
more code than it'd complicate). But ...

- Andres



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

Предыдущее
От: Andres Freund
Дата:
Сообщение: Re: Lowering the ever-growing heap->pd_lower
Следующее
От: Peter Geoghegan
Дата:
Сообщение: Re: Lowering the ever-growing heap->pd_lower