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

Upgrade V8 to 8.6.337 #430

Merged
merged 4 commits into from
Aug 6, 2020
Merged

Conversation

piscisaureus
Copy link
Member

No description provided.

piscisaureus added a commit to piscisaureus/safe_v8 that referenced this pull request Aug 5, 2020
piscisaureus added a commit to piscisaureus/safe_v8 that referenced this pull request Aug 5, 2020
piscisaureus added a commit to piscisaureus/safe_v8 that referenced this pull request Aug 5, 2020
piscisaureus added a commit to piscisaureus/safe_v8 that referenced this pull request Aug 5, 2020
piscisaureus added a commit to piscisaureus/safe_v8 that referenced this pull request Aug 5, 2020
piscisaureus added a commit to piscisaureus/safe_v8 that referenced this pull request Aug 5, 2020
After upgrading to V8 8.6.337, with a 20 MB heap limit the
near-heap-limit callback never gets called before V8 runs out of memory.
However 20 MB is also unrealistically low, so this patch increases the
heap limit to 50 MB.
piscisaureus added a commit to piscisaureus/safe_v8 that referenced this pull request Aug 5, 2020
After upgrading to V8 8.6.337, with a 20 MB heap limit, the
near-heap-limit callback never gets called before V8 runs out of memory.

It turns out that the memory allocation pattern that this test generates
creates so little actual garbage that 'scavenge' type garbage
collections make memory usage go up rather than down. Because of this,
V8 runs out of memory in the middle of a garbage collection cycle, after
it has already decided that there's no need to run the near-heap-limit
callback.

The issue is fixed by making sure that some actual garbage is produced
alongside with the retained objects that will eventually fill up the
heap.
piscisaureus added a commit to piscisaureus/safe_v8 that referenced this pull request Aug 6, 2020
After upgrading to V8 8.6.337, with a 20 MB heap limit, the
near-heap-limit callback never gets called before V8 runs out of memory.

It turns out that this test exhibits memory allocation behavior which
produces so little actual garbage that 'scavenge' type garbage
collections make memory usage go up rather than down. Because of this,
V8 runs out of memory in the middle of a garbage collection cycle, after
it has already decided that there's no need to run the near-heap-limit
callback.

The issue is fixed by making sure that some actual garbage is produced
alongside with the retained objects that will eventually fill up the
heap.
piscisaureus added a commit to piscisaureus/safe_v8 that referenced this pull request Aug 6, 2020
After upgrading to V8 8.6.337, with a 20 MB heap limit, the
near-heap-limit callback never gets called before V8 runs out of memory.

It turns out that this test exhibits memory allocation behavior which
produces so little actual garbage that 'scavenge' type garbage
collections make memory usage go up rather than down. Because of this,
V8 runs out of memory in the middle of a garbage collection cycle, after
it has already decided that there's no need to run the near-heap-limit
callback.

The issue is fixed by making sure that some actual garbage is produced
alongside with the retained objects that will eventually fill up the
heap.
@piscisaureus piscisaureus requested a review from ry August 6, 2020 02:07
After upgrading to V8 8.6.337, with a 20 MB heap limit, the
near-heap-limit callback never gets called before V8 runs out of memory.

It turns out that this test exhibits memory allocation behavior which
produces so little actual garbage that 'scavenge' type garbage
collections make memory usage go up rather than down. Because of this,
V8 runs out of memory in the middle of a garbage collection cycle, after
it has already decided that there's no need to run the near-heap-limit
callback.

The issue is fixed by making sure that some actual garbage is produced
alongside with the retained objects that will eventually fill up the
heap.
Copy link
Member

@ry ry left a comment

Choose a reason for hiding this comment

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

LGTM

@piscisaureus piscisaureus merged commit 954163a into denoland:master Aug 6, 2020
@piscisaureus piscisaureus deleted the upgrade_v8 branch August 6, 2020 02:52
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