Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

perf: memoize repeated ops during compile time #261

Open
wants to merge 3 commits into
base: main
Choose a base branch
from
Open

Conversation

boopathi
Copy link
Member

@boopathi boopathi commented Oct 14, 2024

Depends on #260. Right now it targets #260. After #260 is merged, I'll target branch main.

Memoize repeated computations of collect fields for the same sub-tree. To memoize, use a separate weakMemo based on WeakMap instead of using a memoize4 or memoize5 functions - this is because not all arguments of the function need to participate in the memo key. Only 2 out of 5 or 6 arguments actually contribute to the memo key.

@boopathi boopathi added the minor label Oct 14, 2024
@boopathi boopathi changed the title perf: memoize skip include compilation perf: memoize repeated ops during compile time Oct 14, 2024
Base automatically changed from perf-2 to main October 15, 2024 09:17
@oporkka
Copy link
Member

oporkka commented Oct 16, 2024

Any edge cases we should check? Like against false caching?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants