Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(390)

Side by Side Diff: src/heap/gc-idle-time-handler.cc

Issue 767233003: Perform smaller marking steps incrementally in idle notification. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 6 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2014 the V8 project authors. All rights reserved. 1 // Copyright 2014 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "src/heap/gc-idle-time-handler.h" 5 #include "src/heap/gc-idle-time-handler.h"
6 #include "src/heap/gc-tracer.h" 6 #include "src/heap/gc-tracer.h"
7 #include "src/utils.h" 7 #include "src/utils.h"
8 8
9 namespace v8 { 9 namespace v8 {
10 namespace internal { 10 namespace internal {
(...skipping 232 matching lines...) Expand 10 before | Expand all | Expand 10 after
243 if (heap_state.sweeping_in_progress && 243 if (heap_state.sweeping_in_progress &&
244 static_cast<size_t>(idle_time_in_ms) >= kMinTimeForFinalizeSweeping) { 244 static_cast<size_t>(idle_time_in_ms) >= kMinTimeForFinalizeSweeping) {
245 return GCIdleTimeAction::FinalizeSweeping(); 245 return GCIdleTimeAction::FinalizeSweeping();
246 } 246 }
247 247
248 if (heap_state.incremental_marking_stopped && 248 if (heap_state.incremental_marking_stopped &&
249 !heap_state.can_start_incremental_marking) { 249 !heap_state.can_start_incremental_marking) {
250 return GCIdleTimeAction::Nothing(); 250 return GCIdleTimeAction::Nothing();
251 } 251 }
252 size_t step_size = EstimateMarkingStepSize( 252 size_t step_size = EstimateMarkingStepSize(
253 static_cast<size_t>(idle_time_in_ms), 253 static_cast<size_t>(kIncrementalMarkingStepTimeInMs),
254 heap_state.incremental_marking_speed_in_bytes_per_ms); 254 heap_state.incremental_marking_speed_in_bytes_per_ms);
255 return GCIdleTimeAction::IncrementalMarking(step_size); 255 return GCIdleTimeAction::IncrementalMarking(step_size);
256 } 256 }
257 } 257 }
258 } 258 }
OLDNEW
« no previous file with comments | « src/heap/gc-idle-time-handler.h ('k') | src/heap/heap.cc » ('j') | src/heap/heap.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698