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

memoize the generation of MacrosConfig cache keys per (project, appRoot) #1400

Draft
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

raycohen
Copy link
Contributor

@raycohen raycohen commented Apr 19, 2023

Ref #1399

This is the most aggressive memoization I can think of, computing the cacheKey only once per (project, appRoot) "tuple".

This drops the time spent in babelPluginConfig from about 3 seconds (speedscope in linked ticket) down to about 200ms

Screenshot 2023-04-19 at 5 02 47 PM

@NullVoxPopuli
Copy link
Collaborator

What does performance look like in your app with this change?

@SergeAstapov
Copy link
Collaborator

just a small note, seems related to #1102, not sure if optimisation made there was lost (we don't see that issue, although we may not be using the latest versions yet)

@raycohen
Copy link
Contributor Author

@SergeAstapov Thanks for the call out. That memoization is still in place from what I can tell.

@NullVoxPopuli Updated description with a speedscope image - this dropped time spent here to about 200ms (down from ~3s)

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.

3 participants