pydantic / jiter

Fast iterable JSON parser.
https://crates.io/crates/jiter
MIT License
251 stars 18 forks source link

try to hit some optimizations #44

Closed davidhewitt closed 11 months ago

davidhewitt commented 11 months ago

Try some golfing having been nerd-sniped this morning.

codecov[bot] commented 11 months ago

Codecov Report

Merging #44 (113e59f) into main (36b2354) will increase coverage by 0.01%. The diff coverage is 100.00%.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #44 +/- ## ========================================== + Coverage 89.56% 89.58% +0.01% ========================================== Files 8 8 Lines 1045 1047 +2 ========================================== + Hits 936 938 +2 Misses 109 109 ``` | [Files](https://app.codecov.io/gh/pydantic/jiter/pull/44?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=pydantic) | Coverage Δ | | |---|---|---| | [src/parse.rs](https://app.codecov.io/gh/pydantic/jiter/pull/44?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=pydantic#diff-c3JjL3BhcnNlLnJz) | `98.18% <100.00%> (+0.02%)` | :arrow_up: | ------ [Continue to review full report in Codecov by Sentry](https://app.codecov.io/gh/pydantic/jiter/pull/44?src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=pydantic). > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=pydantic) > `Δ = absolute (impact)`, `ø = not affected`, `? = missing data` > Powered by [Codecov](https://app.codecov.io/gh/pydantic/jiter/pull/44?src=pr&el=footer&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=pydantic). Last update [36b2354...113e59f](https://app.codecov.io/gh/pydantic/jiter/pull/44?src=pr&el=lastupdated&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=pydantic). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=pydantic).
codspeed-hq[bot] commented 11 months ago

CodSpeed Performance Report

Merging #44 will degrade performances by 14.38%

Comparing dh/optimizations (113e59f) with main (36b2354)

Summary

❌ 3 regressions ✅ 34 untouched benchmarks

:warning: Please fix the performance issues or acknowledge them on CodSpeed.

Benchmarks breakdown

Benchmark main dh/optimizations Change
true_array_jiter_value 53.8 µs 62.9 µs -14.38%
big_jiter_value 283.9 ms 319.8 ms -11.23%
python_parse_true_array 58.2 µs 67.2 µs -13.4%