You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Audit the codebase for release binary size reductions #772
PR #771 (#530) needed a size-focused design review to stay within the existing release binary budget. Reusing existing tree primitives, removing an unnecessary generic walker/encoder helper, and avoiding another general sort specialization reduced the measured binary from 1,263,848 to 1,258,784 bytes. The unchanged cap is 1,259,520 bytes, leaving only 736 bytes of headroom.
Extend that review across the entire codebase for v3.0.0. Look for avoidable monomorphization and duplicated specializations, redundant helpers or algorithms, opportunities to reuse existing primitives, and other changes that reduce shipped code without adding complexity. Include the library/CLI and feature-specific native, browser and WASI paths.
Establish reproducible size baselines with compiler, profile, features and target recorded.
Inspect symbol/section contributions and their call sites throughout the codebase.
Produce a ranked inventory of opportunities, with measured before/after byte savings from focused prototypes and the runtime, memory and maintenance tradeoffs.
File and link small, independently reviewable follow-up changes for worthwhile opportunities; explain rejected candidates where size savings would compromise reliability or performance.
Preserve public API, file format, error behaviour, portability and MSRV. Keep the current size cap and coverage floors unchanged; run heavy verification and performance comparisons on the bench machine.
The goal is more release-size headroom while retaining Minigraf's embedded, self-contained, reliability-first design. Use PR #771 and its size/coverage follow-up as the concrete starting example.
Audit report and reproducible evidence are ready for review in #798 (draft, based on v3 3d19abbce).
The baseline CLI is 1,263,592 bytes, just 24 bytes below the current 1,263,616-byte cap. Seven independent source probes, native/library/browser/WASI baselines, packaged-browser measurements, and bench performance comparisons are recorded.
The report explicitly rejects the slower free-page sort, a size-increasing set comparison sort, and the zero-saving Chrono feature change. No production code or cap/coverage threshold has changed. Verification boundaries, including the tmpfs baseline suite and completed disk-backed set integration checks, are documented in the PR.
Leaving #772 open for review/merge of the audit report; the implementation work is separated into the follow-ups above.
Activity
adityamukho commentedon Oct 29, 2026
Audit report and reproducible evidence are ready for review in #798 (draft, based on v3
3d19abbce).The baseline CLI is 1,263,592 bytes, just 24 bytes below the current 1,263,616-byte cap. Seven independent source probes, native/library/browser/WASI baselines, packaged-browser measurements, and bench performance comparisons are recorded.
Linked follow-ups:
The report explicitly rejects the slower free-page sort, a size-increasing set comparison sort, and the zero-saving Chrono feature change. No production code or cap/coverage threshold has changed. Verification boundaries, including the tmpfs baseline suite and completed disk-backed set integration checks, are documented in the PR.
Leaving #772 open for review/merge of the audit report; the implementation work is separated into the follow-ups above.
Merge pull request #798 from project-minigraf/audit/772-binary-size