From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Philipp Stephani Newsgroups: gmane.emacs.devel Subject: Re: JSON/YAML/TOML/etc. parsing performance Date: Sun, 17 Sep 2017 18:46:45 +0000 Message-ID: References: <87poaqhc63.fsf@lifelogs.com> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="001a113cc362e58e9e0559670c9a" X-Trace: blaine.gmane.org 1505674071 12689 195.159.176.226 (17 Sep 2017 18:47:51 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Sun, 17 Sep 2017 18:47:51 +0000 (UTC) To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sun Sep 17 20:47:44 2017 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dtebX-0002qJ-Bz for ged-emacs-devel@m.gmane.org; Sun, 17 Sep 2017 20:47:43 +0200 Original-Received: from localhost ([::1]:33315 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dtebb-0003Ed-6G for ged-emacs-devel@m.gmane.org; Sun, 17 Sep 2017 14:47:47 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:58075) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dtear-0003A5-W1 for emacs-devel@gnu.org; Sun, 17 Sep 2017 14:47:06 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1dtean-0000Ji-L4 for emacs-devel@gnu.org; Sun, 17 Sep 2017 14:47:02 -0400 Original-Received: from mail-io0-x230.google.com ([2607:f8b0:4001:c06::230]:48799) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1dtean-0000JR-FL for emacs-devel@gnu.org; Sun, 17 Sep 2017 14:46:57 -0400 Original-Received: by mail-io0-x230.google.com with SMTP id n69so14287615ioi.5 for ; Sun, 17 Sep 2017 11:46:57 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to; bh=KEq1/lgpDbhquhouVUMfn9vdqLWI1nXOckxaZGFYN2A=; b=d/iGks/Y8SqGr+Hi35RJJT9uqDUFdct0cmZ/muadQH6I6TyIm6mZoNxGKArzFK7l3o ON/afSsqZu03LkmmxjmMF+qpqRxIhcSVhi+ItGiN+OO6lVTCl8A5JlHvWxrcyAl5kAce 7fD1yAhVXRBy+VPyMHtzwfhgo6s1bgkhMNyyQA7ashxnZP97nGZuOQHhN065YRGkNUJH D6/Lyr9f4UbKAqfWW3HoUsdLUxIKfKiBvRQcOtgZRBmCiIWCL9Eyh0dYQN1JCV3vhv2M 1wty8hc4AXbvKoHn5LHpa7UtkTQRzdXtIsKR9+HZOvQ41pGcj0d270+XKZeOCO9kSCdw eu+A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to; bh=KEq1/lgpDbhquhouVUMfn9vdqLWI1nXOckxaZGFYN2A=; b=NVOnYm5s5U7EVEhJyUoflDV/ARKwJxhLrVq12B0hbED0JSxQmGWAk8e6Ng3xbpqxab Caig763vPZ2Z6Vm57Q6edDF7g2VrVztUFn3k+SfmqjSBQ8gTY0NJW2jcJ0t7Qa8+vXY/ 2lD9RPhHdsbmaSu5nquufnkxT8VnkD9QdL3fz6EciWcJPAb0PqoHv7wVKc1wMjx2ouqe NyoNNcyolp7iXhAxhSp4edKHd3uhtMtbnpS08XcJrIAs8YUV0pXxOa3GTL8BIB+X7256 3jHE6Zw2ojvgRQkOrpzOuHAxtvTGiKd4WW6qk/tNTaUqecQoMbOqGsQzZftZ4yR4KHZw 8xfg== X-Gm-Message-State: AHPjjUhTMnSMPQBxnbw2XA22+tBr73iwKhp1rWOlh0qOSrnhSTcNk1aS 0pu2OqwxGvtHhIbqZoOZu4rzFbOdfUuTLtWeN7jyWA== X-Google-Smtp-Source: AOwi7QB51wwBDzglP/3gKhW5XUAo9IzM7Viwv9RE/MmWQg5rogyROqZCkD/qBBkdlrkFaOpTXCt34+Jl6JpAQC2SivQ= X-Received: by 10.202.171.147 with SMTP id u141mr15627271oie.312.1505674016425; Sun, 17 Sep 2017 11:46:56 -0700 (PDT) In-Reply-To: <87poaqhc63.fsf@lifelogs.com> X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2607:f8b0:4001:c06::230 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.org gmane.emacs.devel:218419 Archived-At: --001a113cc362e58e9e0559670c9a Content-Type: text/plain; charset="UTF-8" Ted Zlatanov schrieb am Sa., 16. Sep. 2017 um 17:55 Uhr: > I wanted to ask if there's any chance of improving the parsing > performance of JSON, YAML, TOML, and similar data formats. It's pretty > poor today. > > That could be done in the core with C code, improved Lisp code, > integration with an external library, or a mix of those. > I don't know much about the others, but given the importance of JSON as data exchange and serialization format, I think it's worthwhile to invest some time here. I've implemented a wrapper around the json-c library (license: Expat/X11/MIT), resulting in significant speedups using the test data from https://github.com/miloyip/nativejson-benchmark: a factor of 3.9 to 6.4 for parsing, and a factor of 27 to 67 for serializing. If people agree that this is useful I can send a patch. --001a113cc362e58e9e0559670c9a Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable


Ted Zl= atanov <tzz@lifelogs.com> sch= rieb am Sa., 16. Sep. 2017 um 17:55=C2=A0Uhr:
I wanted to ask if there's any chance of improving the parsi= ng
performance of JSON, YAML, TOML, and similar data formats. It's pretty<= br> poor today.

That could be done in the core with C code, improved Lisp code,
integration with an external library, or a mix of those.

I don't know much about the others, bu= t given the importance of JSON as data exchange and serialization format, I= think it's worthwhile to invest some time here. I've implemented a= wrapper around the json-c library (license: Expat/X11/MIT), resulting in s= ignificant speedups using the test data from https://github.com/miloyip/nativejson-benchma= rk: a factor of 3.9 to 6.4 for parsing, and a factor of 27 to 67 for se= rializing. If people agree that this is useful I can send a patch.
--001a113cc362e58e9e0559670c9a--