Closed TheVeryDarkness closed 5 months ago
The recent updates introduce benchmarking capabilities for JSON parsing within the derive
directory. Dependencies for criterion
and serde_json
were added, and a new benchmark for JSON parsing was configured. Additionally, json.rs
was created to define and benchmark parsing functions for both deep and shallow JSON objects using pest3
and serde_json
.
File/Path | Change Summary |
---|---|
derive/Cargo.toml | Added dependencies: criterion and serde_json ; Added benchmark configuration for JSON |
derive/benches/json.rs | Introduced JsonParser struct and benchmarking functions for parsing JSON objects |
In the realm of code so bright and keen,
Benchmarks now dance on the JSON scene.
Withserde_json
andcriterion
in play,
Parsing speeds are timed, come what may.
Deep or shallow, the objects we parse,
Our code now sings, a benchmarking star! 🌟
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?
And we can add some features to improve typed api's performance, such as using an allocator/arena and adding a rule optimizer (but it's harder on typed api, and in some cases it can only work as a linter). I may have some time after around a month. @tomtau Do you have any plan on our future works?
Thanks a lot @TheVeryDarkness !
@tomtau Do you have any plan on our future works?
I opened a few issues for near-term priorities: https://github.com/pest-parser/pest3/issues feel free to comment on any that you'd be interested in tackling
Added a benchmark, which parses automatically generated json data.
I think the performance is much worse than pest. Maybe test on pest later.
And I think we should add tests and benchmarks to CI.
Summary by CodeRabbit
pest3
andserde_json
.