Skip to content

perf(mojo): pre-size 2048-byte n=1 buffers and faster strings - #144

Merged
leo-gan merged 1 commit into
masterfrom
perf-remaining-budget
Sep 9, 2026
Merged

perf(mojo): pre-size 2048-byte n=1 buffers and faster strings#144
leo-gan merged 1 commit into
masterfrom
perf-remaining-budget

Conversation

@leo-gan

@leo-gan leo-gan commented Sep 9, 2026

Copy link
Copy Markdown
Owner

Summary

  • Official n=1 writer capacity 256 → 2048 (payloads are 411–491 bytes)
  • Re-vendor gld-json Error fixes #8: single-scan string write, ASCII decode, reserved lists
  • Document items / event attrs reserved

Official all-single vs #143 (median skip warmup):

cell #143 ser/des now ser/des Ember vs Ember
message n=1 258 / 484 256 / 418 248 / 540 0.97× / 1.29×
document n=1 2144 / 1563 555 / 1273 502 / 1615 0.90× / 1.27×
strings n=1 2257 / 4835 658 / 2894 595 / 1147 0.90× / 0.40×
event n=1 786 / 1841 369 / 1144 331 / 949 0.90× / 0.83×
message n=100 16576 / 39155 16303 / 32895 19613 / 31738 1.20× / 0.96×

Fidelity 1.0. 7/20 official cells now beat Ember. 1.5× floor still not met.

Validation

  • mojo test_roundtrip.mojo ok
  • all-single json stem 2026-09-09-150051

Official n=1 document/strings/telemetry were 411–491 bytes written
into a 256-byte WireWriter. Vendor gld-json #8 string/list path.
@leo-gan
leo-gan merged commit 2f4ddd1 into master Sep 9, 2026
15 checks passed
@leo-gan
leo-gan deleted the perf-remaining-budget branch September 9, 2026 22:31
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.

1 participant