Integrate concurrent sweeping with incremental marking.

BUG=

Review URL: https://codereview.chromium.org/12527011

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@13852 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
This commit is contained in:
hpayer@chromium.org 2013-03-07 09:27:49 +00:00
parent 250edbdc64
commit 2c9789e17f
2 changed files with 7 additions and 2 deletions

View File

@ -1695,6 +1695,12 @@ class Heap {
return sweeping_complete;
}
bool EnsureSweepersProgressed(int step_size) {
bool sweeping_complete = old_data_space()->EnsureSweeperProgress(step_size);
sweeping_complete &= old_pointer_space()->EnsureSweeperProgress(step_size);
return sweeping_complete;
}
ExternalStringTable* external_string_table() {
return &external_string_table_;
}

View File

@ -562,7 +562,6 @@ void IncrementalMarking::UncommitMarkingDeque() {
void IncrementalMarking::Start() {
ASSERT(!heap_->mark_compact_collector()->IsConcurrentSweepingInProgress());
if (FLAG_trace_incremental_marking) {
PrintF("[IncrementalMarking] Start\n");
}
@ -901,7 +900,7 @@ void IncrementalMarking::Step(intptr_t allocated_bytes,
}
if (state_ == SWEEPING) {
if (heap_->AdvanceSweepers(static_cast<int>(bytes_to_process))) {
if (heap_->EnsureSweepersProgressed(static_cast<int>(bytes_to_process))) {
bytes_scanned_ = 0;
StartMarking(PREVENT_COMPACTION);
}