Skip to content

perf(memo): flatten dependency sections directly - #83

Closed
anmonteiro wants to merge 1 commit into
mainfrom
perf/memo-flatten-dependencies
Closed

perf(memo): flatten dependency sections directly#83
anmonteiro wants to merge 1 commit into
mainfrom
perf/memo-flatten-dependencies

Conversation

@anmonteiro

@anmonteiro anmonteiro commented Aug 21, 2026

Copy link
Copy Markdown
Owner

Flatten memo dependency sections directly into their final order instead of building and concatenating intermediate lists. Empty and already-normalized single sections are returned directly.

Local benchmarks show 3–40% lower CPU time and 21–69% fewer minor-heap words for sections requiring traversal; the normalized-single-section path becomes O(1) with zero allocation. The benchmark harness is not included.

@anmonteiro
anmonteiro force-pushed the perf/memo-flatten-dependencies branch from 4012d20 to 01be20f Compare August 21, 2026 23:15
Signed-off-by: Antonio Nuno Monteiro <anmonteiro@gmail.com>
@anmonteiro
anmonteiro force-pushed the perf/memo-flatten-dependencies branch from 01be20f to fff3a55 Compare August 21, 2026 23:18
@anmonteiro

Copy link
Copy Markdown
Owner Author

Closing in favor of the overlapping upstream work in ocaml#15683 and ocaml#15684.

@anmonteiro anmonteiro closed this Aug 22, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant