Hi,
I did benchmarks of json parsing here it is what I get:
| test | non-gc avg (s) | gc avg (s) | gcs avg | tot avg (s) | tot avg err (s) |
|--------------+----------------+------------+---------+-------------+-----------------|
| json-parsing | 2.57 | 3.32 | 318 | 5.89 | 0.10 |
|--------------+----------------+------------+---------+-------------+-----------------|
| total | 2.57 | 3.32 | 318 | 5.89 | 0.10 |
Native:
| test | non-gc avg (s) | gc avg (s) | gcs avg | tot avg (s) | tot avg err (s) |
|--------------+----------------+------------+---------+-------------+-----------------|
| json-parsing | 1.71 | 4.31 | 343 | 6.02 | 0.01 |
|--------------+----------------+------------+---------+-------------+-----------------|
| total | 1.71 | 4.31 | 343 | 6.02 | 0.01 |
It looks like this is bellow the average speedup you might wanna take a look:
Here it is the benchmark code:
(require 'cl-lib)
(require 'json)
(defvar json-parsing-input (with-temp-buffer
(insert-file-contents-literally "benchmarks/sample.json")
(buffer-string)))
(defun elb-json-parsing-entry ()
(cl-loop repeat 1000
do (json-read-from-string json-parsing-input)))
Thanks,
Ivan