Re: Performance improvements for src/port/snprintf.c

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Performance improvements for src/port/snprintf.c
Дата
Msg-id 2845.1538589098@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: Performance improvements for src/port/snprintf.c  (Andres Freund <andres@anarazel.de>)
Ответы Re: Performance improvements for src/port/snprintf.c
Список pgsql-hackers
Andres Freund <andres@anarazel.de> writes:
> On 2018-10-03 13:18:35 -0400, Tom Lane wrote:
>> Having said that, maybe there's a case for changing the type spec
>> in only the va_arg() call, and leaving snprintf's related local
>> variables as int64.  (Is that what you actually meant?)  Then,
>> if long long really is different from int64, at least we have
>> predictable truncation behavior after fetching the value, rather
>> than undefined behavior while fetching it.

> Hm. I guess that'd be a bit better, but I'm not sure it's worth it. How
> about we simply add a static assert that long long isn't bigger than
> int64?

WFM, I'll make it happen.

            regards, tom lane


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

Предыдущее
От: Andres Freund
Дата:
Сообщение: Re: Performance improvements for src/port/snprintf.c
Следующее
От: Tom Lane
Дата:
Сообщение: Re: Performance improvements for src/port/snprintf.c