bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#31138: Native json slower than json.el


From: yyoncho
Subject: bug#31138: Native json slower than json.el
Date: Tue, 26 Mar 2019 19:45:38 +0200

Hi Eli,

I think I get similar results.

* ~5mb/s for ~500b message
* ~15mb/s for ~850kb message

So it is like ~500ms for 10mb.

Thanks,
Ivan


On Tue, Mar 26, 2019 at 6:14 PM Eli Zaretskii <eliz@gnu.org> wrote:
> From: yyoncho <yyoncho@gmail.com>
> Date: Mon, 25 Mar 2019 23:34:38 +0200
> Cc: Sébastien Chapuis <sebastien@chapu.is>,
>       31138@debbugs.gnu.org
>
> 3. Even in the best case scenario native parsing is not fast enough. In lsp-mode, you might receive 3.5mb
> json as a server-side response while you are typing. E. g. I might type "abc" and get 10.5 mb json.

What kind of throughput do you get with native JSON parsing when you
submit a 10MB JSON to it?  My testing indicates that decoding strings
by UTF-8 runs at about 50 msec per MByte for short strings, and about
4 times faster for very large strings.  How does this compare with the
overall time for processing a 10MB JSON?

> Alternatively, we (lsp-mode team) will be able to solve all these in a dynamic module if emacs module
> mechanism is extended to allow creating emacs lisp structures efficiently.

I think we should only consider this after we profile JSON parsing and
see which parts take the most processing time.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]