Re: Speed up JSON escape processing with SIMD plus other optimisations

Поиск
Список
Период
Сортировка
От Melih Mutlu
Тема Re: Speed up JSON escape processing with SIMD plus other optimisations
Дата
Msg-id CAGPVpCSr8TJZpsVUWciR7eVWLeEzMr1vw7gvEALUQwB4Upmhjg@mail.gmail.com
обсуждение исходный текст
Ответ на Re: Speed up JSON escape processing with SIMD plus other optimisations  (David Rowley <dgrowleyml@gmail.com>)
Ответы Re: Speed up JSON escape processing with SIMD plus other optimisations
Re: Speed up JSON escape processing with SIMD plus other optimisations
Список pgsql-hackers
Hi David,

Thanks for the patch.

In 0001 patch, I see that there are some escape_json() calls with NUL-terminated strings and gets the length by calling strlen(), like below:

- escape_json(&buf, "timestamp");
+ escape_json(&buf, "timestamp", strlen("timestamp"));

 Wouldn't using escape_json_cstring() be better instead? IIUC there isn't much difference between escape_json() and escape_json_cstring(), right? We would avoid strlen() with escape_json_cstring().

Regards,
--
Melih Mutlu
Microsoft

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

Предыдущее
От: Andrew Dunstan
Дата:
Сообщение: Re: RFC: adding pytest as a supported test framework
Следующее
От: Andrew Dunstan
Дата:
Сообщение: Re: Speed up JSON escape processing with SIMD plus other optimisations