-
-
Notifications
You must be signed in to change notification settings - Fork 35.4k
doc: add new useful V8 option #42575
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
Changes from 4 commits
a28ef1b
b960c66
3ae0f49
6813f99
7b1739c
dddff28
a05b327
eb1eec7
d1defe3
91a151a
0dfd5e5
f91e536
1bb2ad7
4fc45b6
e1c0732
4ef953f
5574419
1deaca4
db7d07d
baa9c9b
5411215
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -1980,6 +1980,23 @@ On a machine with 2 GB of memory, consider setting this to | |
| $ node --max-old-space-size=1536 index.js | ||
| ``` | ||
|
|
||
| ### `--max_semi_space_size=SIZE` (in megabytes) | ||
|
|
||
| Sets the maximum | ||
| [semi\_space](https://www.memorymanagement.org/glossary/s.html#semi.space) | ||
|
JialuZhang-intel marked this conversation as resolved.
Outdated
|
||
| size for V8's [scavenge](https://v8.dev/blog/orinoco-parallel-scavenger) | ||
| garbage collector. | ||
|
JialuZhang-intel marked this conversation as resolved.
Outdated
|
||
| Increase the value of max\_semi\_space\_size may bring | ||
| the throughput improvement for node and the cost is more memory consumption. | ||
|
JialuZhang-intel marked this conversation as resolved.
Outdated
|
||
| The actual throughput improvement and memory consumption | ||
| are relevant to your application | ||
| ([reference](https://github.com/nodejs/node/issues/42511)). | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I'm not sure I understand this sentence, do you mean it's relevant to any Node.js application, and if so, how do you know?
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I tuned the max_semi_space_size value and tested it on two workloads, this is the results: |
||
|
|
||
| _The default max\_semi\_space\_size is | ||
|
JialuZhang-intel marked this conversation as resolved.
Outdated
|
||
| 16MB for 64-bit systems and 8MB for 32-bit systems. | ||
|
JialuZhang-intel marked this conversation as resolved.
Outdated
|
||
| The recommended value is 64MB or 128MB if your system has enough | ||
|
JialuZhang-intel marked this conversation as resolved.
Outdated
|
||
| memory._ | ||
|
|
||
| [Chrome DevTools Protocol]: https://chromedevtools.github.io/devtools-protocol/ | ||
| [CommonJS]: modules.md | ||
| [ECMAScript module loader]: esm.md#loaders | ||
|
|
||

Uh oh!
There was an error while loading. Please reload this page.