Skip to content

Fix json_pipeline_small parse threshold#704

Merged
proggeramlug merged 5 commits into
PerryTS:mainfrom
TheHypnoo:feat/json-pipeline-small-direct-parser
May 12, 2026
Merged

Fix json_pipeline_small parse threshold#704
proggeramlug merged 5 commits into
PerryTS:mainfrom
TheHypnoo:feat/json-pipeline-small-direct-parser

Conversation

@TheHypnoo
Copy link
Copy Markdown
Contributor

@TheHypnoo TheHypnoo commented May 11, 2026

Summary

Fixes #437 by raising the lazy JSON parse auto-mode lower bound from 1 KB to 64 KB. The 21 KB json_pipeline_small fixture now stays on the direct parser, avoiding lazy-header and forced-materialization overhead on an iterate-all workload.

This also updates the lazy JSON predicate regression fixture so it still exceeds the auto-mode threshold and refreshes the related docs.

Impact

  • json_pipeline_small now runs through the faster direct parser in auto mode.
  • The lazy path remains available for targeted tests via PERRY_JSON_TAPE=1.
  • Larger auto-mode lazy payloads are still limited to the 64 KB..16 MB window.

Measured Improvement

On the local 20-run issue reproduction:

  • Before: issue reported ~47 ms median vs a <=41 ms target.
  • After: 28.369 ms median, 1.172 ms standard deviation.
  • Output hash remains 7fc66fa8 and output_match=true for all measured runs.

Conflict Resolution

Rebased onto the latest main (0.5.867) and resolved the conflict in Cargo.lock by keeping the current base lockfile. The PR now only changes the runtime threshold, lazy JSON test fixture, and related docs.

Validation

  • cargo check --release -p perry-runtime --locked
  • Compiled and ran test-files/test_json_lazy_predicates.ts with Perry
  • Rebuilt the json_pipeline_small Perry workload and ran 20 measured iterations with the honest_bench output checker

@TheHypnoo TheHypnoo force-pushed the feat/json-pipeline-small-direct-parser branch from 11cb8e2 to 6130337 Compare May 11, 2026 18:10
@TheHypnoo TheHypnoo force-pushed the feat/json-pipeline-small-direct-parser branch from 6130337 to 2920ae9 Compare May 12, 2026 09:07
@proggeramlug proggeramlug merged commit b02fe02 into PerryTS:main May 12, 2026
9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

honest_bench: json_pipeline_small +19.6% over baseline at variance edge — measure with longer warmup

2 participants