Re: [PATCH] Optimize json_lex_string by batching character copying - Mailing list pgsql-hackers

From John Naylor
Subject Re: [PATCH] Optimize json_lex_string by batching character copying
Date
Msg-id CAFBsxsEcr5H8ydKR66VZeJo8buwScOsHX71z5KVcdvmx=YDC9g@mail.gmail.com
Whole thread Raw
In response to Re: [PATCH] Optimize json_lex_string by batching character copying  (John Naylor <john.naylor@enterprisedb.com>)
Responses Re: [PATCH] Optimize json_lex_string by batching character copying
List pgsql-hackers
On Tue, Aug 23, 2022 at 1:03 PM John Naylor
<john.naylor@enterprisedb.com> wrote:
>
> LGTM overall. My plan is to split out the json piece, adding tests for
> that, and commit the infrastructure for it fairly soon.

Here's the final piece. I debated how many tests to add and decided it
was probably enough to add one each for checking quotes and
backslashes in the fast path. There is one cosmetic change in the
code: Before, the vectorized less-equal check compared to 0x1F, but
the byte-wise path did so with < 32. I made them both "less-equal 31"
for consistency. I'll commit this by the end of the week unless anyone
has a better idea about testing.

-- 
John Naylor
EDB: http://www.enterprisedb.com

Attachment

pgsql-hackers by date:

Previous
From: Richard Guo
Date:
Subject: Re: Stack overflow issue
Next
From: Nathan Bossart
Date:
Subject: Re: effective_multixact_freeze_max_age issue