Skip to content

perf: User Map to optimize performance#4122

Merged
lukastaegert merged 2 commits into
rollup:masterfrom
zhihuahuang:perf-traceMappings-nameIndexMap
Jun 6, 2021
Merged

perf: User Map to optimize performance#4122
lukastaegert merged 2 commits into
rollup:masterfrom
zhihuahuang:perf-traceMappings-nameIndexMap

Conversation

@zhihuahuang

@zhihuahuang zhihuahuang commented Jun 4, 2021

Copy link
Copy Markdown
Contributor

This PR contains:

  • bugfix
  • feature
  • refactor
  • documentation
  • other

Are tests included?

  • yes (bugfixes and features will not be merged without tests)
  • no

Breaking Changes?

  • yes (breaking changes will not be merged unless absolutely necessary)
  • no

Description

Use Map to optimize performance of traceMappings.

Before:
image

After:
image

@github-actions

github-actions Bot commented Jun 4, 2021

Copy link
Copy Markdown

Thank you for your contribution! ❤️

You can try out this pull request locally by installing Rollup via

npm install izevo/rollup#perf-traceMappings-nameIndexMap

or load it into the REPL:
https://rollupjs.org/repl/?pr=4122

@lukastaegert lukastaegert left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great find, thanks a lot!

@lukastaegert lukastaegert left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah, it. seems a lot of tests are broken by this change. Could you have a look?

@zhihuahuang zhihuahuang force-pushed the perf-traceMappings-nameIndexMap branch from b4abfa2 to ab9ad57 Compare June 6, 2021 08:49
@zhihuahuang

Copy link
Copy Markdown
Contributor Author

My mistake. I created a bug and it is fixed now.
Please review again.

@lukastaegert lukastaegert merged commit 172c114 into rollup:master Jun 6, 2021
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.

2 participants