|
From: | Dmitry Gutov |
Subject: | bug#31138: Native json slower than json.el |
Date: | Mon, 22 Apr 2019 20:11:33 +0300 |
User-agent: | Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.6.1 |
On 22.04.2019 19:49, Eli Zaretskii wrote:
Btw, we could somewhat speed up even the case where we do call code_convert_string, by avoiding the call to make_specified_string. That's because decode_coding_object, called by code_convert_string to perform the decoding, is capable of decoding a C string, if we set up its argument accordingly.
Guess we could test that with a non-ascii sample.I was kind of expecting to continue on the "fast validation" route, and check whether DATA contains non-ASCII bytes in the exact way we want them. And simply abort otherwise.
You can see one example of that in w32select.c:w32-get-clipboard-data.
Hmm, I'm not seeing any calls to code_convert_string in w32select.c.
[Prev in Thread] | Current Thread | [Next in Thread] |