Commit f03196ba authored by Dominik Inführ's avatar Dominik Inführ Committed by Commit Bot

[test] Test for maximum capacity before growing

NewSpace::Grow shouldn't be invoked when the maximum semi space size
was already reached.

Bug: v8:11199
Change-Id: I78ba71b7a043f0a515be188f2023e301d6bc6eed
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2584864Reviewed-by: 's avatarHannes Payer <hpayer@chromium.org>
Commit-Queue: Dominik Inführ <dinfuehr@chromium.org>
Cr-Commit-Position: refs/heads/master@{#71769}
parent f6ae3c47
......@@ -251,7 +251,9 @@ void EnsureFlagLocalHeapsEnabled() {
void GrowNewSpace(Heap* heap) {
SafepointScope scope(heap);
heap->new_space()->Grow();
if (!heap->new_space()->IsAtMaximumCapacity()) {
heap->new_space()->Grow();
}
}
void GrowNewSpaceToMaximumCapacity(Heap* heap) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment