tiny step toward threading: reduce dependence on setlocale()

Поиск
Список
Период
Сортировка
От Jeff Davis
Тема tiny step toward threading: reduce dependence on setlocale()
Дата
Msg-id 2228884bb1f1a02614b39f71a90c94d2cc8a3a2f.camel@j-davis.com
обсуждение исходный текст
Ответы Re: tiny step toward threading: reduce dependence on setlocale()
Список pgsql-hackers
There was an unconference session at pgconf.dev related to threading
support. One of the problems identified was setlocale().

The attached series of patches make collation not depend on
setlocale(), even if the database collation uses the libc provider.

Since commit 8d9a9f034e, all supported platforms have locale_t, so we
can use strcoll_l(), etc., or uselocale() when no "_l" variant is
available.

A brief test shows that there may be a performance regression for libc
default collations. But if so, I'm not sure that's avoidable if the
goal is to take away setlocale. I'll see if removing the extra branches
mitigates it.


--
Jeff Davis
PostgreSQL Contributor Team - AWS



Вложения

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

Предыдущее
От: Heikki Linnakangas
Дата:
Сообщение: Re: [multithreading] extension compatibility
Следующее
От: Michael Paquier
Дата:
Сообщение: Re: ALTER TABLE SET ACCESS METHOD on partitioned tables