Go back to doubling the size when growing new space.

Our memory tests show little improvement by only growing by 50%.

Review URL: http://codereview.chromium.org/174133

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@2728 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
This commit is contained in:
ager@chromium.org 2009-08-20 08:12:30 +00:00
parent cd4d95bc1c
commit 94a3009b04
2 changed files with 3 additions and 2 deletions

View File

@ -1079,9 +1079,9 @@ void SemiSpace::TearDown() {
bool SemiSpace::Grow() {
// Commit 50% extra space but only up to maximum capacity.
// Double the semispace size but only up to maximum capacity.
int maximum_extra = maximum_capacity_ - capacity_;
int extra = Min(RoundUp(capacity_ / 2, OS::AllocateAlignment()),
int extra = Min(RoundUp(capacity_, OS::AllocateAlignment()),
maximum_extra);
if (!MemoryAllocator::CommitBlock(high(), extra, executable())) {
return false;

View File

@ -156,6 +156,7 @@ uint32_t V8::Random() {
return (hi << 16) + (lo & 0xFFFF);
}
void V8::IdleNotification(bool is_high_priority) {
if (!FLAG_use_idle_notification) return;
// Ignore high priority instances of V8.