Re: slab allocator performance issues

Поиск
Список
Период
Сортировка
От Ranier Vilela
Тема Re: slab allocator performance issues
Дата
Msg-id CAEudQAqNVG6G3ALb2Bx9qpK0aSMxv4z7aWPJET5A-Z6r51_9gA@mail.gmail.com
обсуждение исходный текст
Ответ на Re: slab allocator performance issues  (David Rowley <dgrowleyml@gmail.com>)
Список pgsql-hackers
Em ter., 20 de jul. de 2021 às 11:15, David Rowley <dgrowleyml@gmail.com> escreveu:
On Tue, 20 Jul 2021 at 10:04, Ranier Vilela <ranier.vf@gmail.com> wrote:
> Perhaps you would agree with me that in the most absolute of times, malloc will not fail.
> So it makes more sense to test:
> if (ret != NULL)
> than
> if (ret == NULL)

I think it'd be better to use unlikely() for that.
Sure, it can be, but in this case, there is no way to reduce the scope.

regards,
Ranier Vilela

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

Предыдущее
От: David Rowley
Дата:
Сообщение: Re: slab allocator performance issues
Следующее
От: Alvaro Herrera
Дата:
Сообщение: Re: Rename of triggers for partitioned tables