Commit 31493412 authored by ulan@chromium.org's avatar ulan@chromium.org

Do not update survival rate if the new space size is zero.

BUG=v8:2333
LOG=N
R=hpayer@chromium.org

Review URL: https://chromiumcodereview.appspot.com/48443002

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@17753 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
parent 9f4591c3
......@@ -939,6 +939,8 @@ void Heap::ClearNormalizedMapCaches() {
void Heap::UpdateSurvivalRateTrend(int start_new_space_size) {
if (start_new_space_size == 0) return;
double survival_rate =
(static_cast<double>(young_survivors_after_last_gc_) * 100) /
start_new_space_size;
......
......@@ -17131,6 +17131,14 @@ TEST(Regress2107) {
CHECK_LT(final_size, initial_size + 1);
}
TEST(Regress2333) {
LocalContext env;
for (int i = 0; i < 3; i++) {
CcTest::heap()->PerformScavenge();
}
}
static uint32_t* stack_limit;
static void GetStackLimitCallback(
......
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