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

Change forEach to forEachLimit when emitting assets #8639

Merged
merged 3 commits into from Jan 16, 2019

Conversation

sokra
Copy link
Member

@sokra sokra commented Jan 16, 2019

cherry-picked from #8609

What kind of change does this PR introduce?
memory usage improvement

Did you add tests for your changes?
N/A

Does this PR introduce a breaking change?
no

What needs to be documented once your changes are merged?
nothing

@webpack-bot
Copy link
Contributor

Thank you for your pull request! The most important CI builds succeeded, we’ll review the pull request soon.

@webpack-bot
Copy link
Contributor

For maintainers only:

  • This need to be documented (issue in webpack/webpack.js.org will be filed when merged)

@dav-is
Copy link
Contributor

dav-is commented Jan 16, 2019

This change doesn't improve memory usage. It only delays the allocation. The memory is never freed. With this change alone, our process still runs out of memory.

@sokra
Copy link
Member Author

sokra commented Jan 16, 2019

This change doesn't improve memory usage. It only delays the allocation. The memory is never freed.

It improves memory usage a bit, because only 15 buffers allocated here are used at the same time.

I know that it's not free. I'll comment on the other PR.

@sokra sokra merged commit 03ffa48 into master Jan 16, 2019
@sokra sokra deleted the memory/limit-parallelism branch January 16, 2019 22:22
@axetroy
Copy link

axetroy commented Feb 9, 2019

If you change the forEach elsewhere to forEachLimit, can we improve memory usage?

Because the latest version of webpack still has problems with excessive memory.

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.

None yet

4 participants