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

Node >= 12.5 OSX memory spike #28558

Closed
chaffeqa opened this issue Jul 5, 2019 · 5 comments
Closed

Node >= 12.5 OSX memory spike #28558

chaffeqa opened this issue Jul 5, 2019 · 5 comments
Labels
memory Issues and PRs related to the memory management or memory footprint.

Comments

@chaffeqa
Copy link

chaffeqa commented Jul 5, 2019

  • 12.5.0:
  • Darwin Quinns-MacBook-Pro-2.local 18.6.0 Darwin Kernel Version 18.6.0: Thu Apr 25 23:16:27 PDT 2019; root:xnu-4903.261.4~2/RELEASE_X86_64 x86_64:

When running a after.js app (React + babel + webpack) on OSX, can reproduce that switching from 12.4 to 12.5/12.6 that the node process spikes on initial startup in virtual memory and in some cases continues to rise until the process crashes. 12.4 stays consistent.

In looking at bugs + changes, Im suspecting v8 snapshot on osx, but have no way to determine (open to suggestions on debugging).

Including an OSX sample of mem usage on the process

node-12.6-mem-bug.txt

@Trott
Copy link
Member

Trott commented Jul 5, 2019

@nodejs/platform-macos @joyeecheung

@joyeecheung
Copy link
Member

Can you capture a core dump and use https://github.com/nodejs/llnode/ to try listing all types of objects with v8 findjsobjects? If the instance becomes too big using ulimit -v to limit the virtual memory allowed should be helpful.

@joyeecheung
Copy link
Member

Alternatively, you can try building Node.js with --without-node-snapshot in the configure option, and use that to see if the issue reproduces with a no-snapshot build. The guide on building Node.js is https://github.com/nodejs/node/blob/master/BUILDING.md#building-nodejs-on-supported-platforms

(which reminds me it should be possible to make this a run-time option)

@chaffeqa
Copy link
Author

chaffeqa commented Aug 5, 2019

Sorry I have been slammed with work and havent had time to poke around :(

I did notice though in a quick glance at 12.7 updates: #27508

Going to try 12.7 and see if that magically fixes my error, will let you know!

@mikehardy
Copy link

12.7 does not seem to fix it but I believe from #29001 that the PR to update V8 #28918 appears to fix it. That one is in motion at this moment (with comments and CI builds happening) so perhaps 12.9 will be a release with improved behavior. This may be a duplicate of #29001 though

@jasnell jasnell added the memory Issues and PRs related to the memory management or memory footprint. label Jun 26, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
memory Issues and PRs related to the memory management or memory footprint.
Projects
None yet
Development

No branches or pull requests

6 participants