Skip to content

perf(core): lazily allocate row geometry index - #49

Merged
chh-ay merged 2 commits into
0.4.0from
perf/lazy-uniform-offset-index
Jul 27, 2026
Merged

perf(core): lazily allocate row geometry index#49
chh-ay merged 2 commits into
0.4.0from
perf/lazy-uniform-offset-index

Conversation

@chh-ay

@chh-ay chh-ay commented Jul 27, 2026

Copy link
Copy Markdown
Owner

Summary

  • represent uniform row geometry arithmetically instead of eagerly allocating and building two million-entry typed arrays
  • materialize the dense height/Fenwick backing stores only on the first custom row height or non-default inserted band
  • retain exact offset, structural edit, custom-height, scaled-scroll, and allocation-error behavior
  • record backingStoreBytes in the million-row diagnostic contract and refresh the three-round evidence

Measurement

  • direct 1M-row constructor baseline: 5.871 ms median, 16,000,008 typed-array bytes
  • optimized direct constructor: 0.000270 ms median, 0 backing-store bytes
  • retained browser diagnostic: prior 6.90-7.11 ms/operation; now 0.000119-0.000125 ms/operation across three rounds
  • all 12 diagnostic cells passed; formula, long-text, and fractional-scroll scenarios remained within their prior absolute ranges

Verification

  • bun test packages/core/test: 765 passed
  • focused core/bench tests: 29 passed
  • repository bun run typecheck: passed
  • Biome check on changed source: passed
  • retained diagnostic replay: 12/12 passed
  • changeset validation against 0.4.0: passed

@vercel

vercel Bot commented Jul 27, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
sheetwrite Ready Ready Preview, Comment Jul 27, 2026 3:44pm

@chh-ay
chh-ay merged commit ce1e404 into 0.4.0 Jul 27, 2026
11 checks passed
@chh-ay
chh-ay deleted the perf/lazy-uniform-offset-index branch July 27, 2026 15:51
@chh-ay chh-ay mentioned this pull request Jul 27, 2026
36 tasks
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