Version 3.16.12
Performance and stability improvements on all platforms.
git-svn-id: http://v8.googlecode.com/svn/trunk@13573 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
diff --git a/src/heap.cc b/src/heap.cc
index 14c44e8..8d398ec 100644
--- a/src/heap.cc
+++ b/src/heap.cc
@@ -145,6 +145,8 @@
min_in_mutator_(kMaxInt),
alive_after_last_gc_(0),
last_gc_end_timestamp_(0.0),
+ marking_time_(0.0),
+ sweeping_time_(0.0),
store_buffer_(this),
marking_(this),
incremental_marking_(this),
@@ -1306,7 +1308,8 @@
incremental_marking()->PrepareForScavenge();
- AdvanceSweepers(static_cast<int>(new_space_.Size()));
+ paged_space(OLD_DATA_SPACE)->EnsureSweeperProgress(new_space_.Size());
+ paged_space(OLD_POINTER_SPACE)->EnsureSweeperProgress(new_space_.Size());
// Flip the semispaces. After flipping, to space is empty, from space has
// live objects.
@@ -5418,9 +5421,9 @@
// 3. many lazy sweep steps.
// Use mark-sweep-compact events to count incremental GCs in a round.
-
if (incremental_marking()->IsStopped()) {
- if (!IsSweepingComplete() &&
+ if (!mark_compact_collector()->AreSweeperThreadsActivated() &&
+ !IsSweepingComplete() &&
!AdvanceSweepers(static_cast<int>(step_size))) {
return false;
}
@@ -6338,7 +6341,7 @@
#endif
if (FLAG_print_cumulative_gc_stat) {
- PrintF("\n\n");
+ PrintF("\n");
PrintF("gc_count=%d ", gc_count_);
PrintF("mark_sweep_count=%d ", ms_count_);
PrintF("max_gc_pause=%d ", get_max_gc_pause());
@@ -6346,6 +6349,8 @@
PrintF("min_in_mutator=%d ", get_min_in_mutator());
PrintF("max_alive_after_gc=%" V8_PTR_PREFIX "d ",
get_max_alive_after_gc());
+ PrintF("total_marking_time=%f ", marking_time());
+ PrintF("total_sweeping_time=%f ", sweeping_time());
PrintF("\n\n");
}
@@ -7036,6 +7041,9 @@
if (collector_ == SCAVENGER && FLAG_trace_gc_ignore_scavenger) return;
+ heap_->AddMarkingTime(scopes_[Scope::MC_MARK]);
+
+ if (FLAG_print_cumulative_gc_stat && !FLAG_trace_gc) return;
PrintPID("%8.0f ms: ", heap_->isolate()->time_millis_since_init());
if (!FLAG_trace_gc_nvp) {