Commit a9cab08e authored by Michael Lippautz's avatar Michael Lippautz Committed by Commit Bot

[heap] Re-enable parallel marking

Bug: chromium:750084
Change-Id: I3d449ab76101100866b18db776b9f282154a77d9
Reviewed-on: https://chromium-review.googlesource.com/768679
Commit-Queue: Michael Lippautz <mlippautz@chromium.org>
Reviewed-by: 's avatarUlan Degenbaev <ulan@chromium.org>
Cr-Commit-Position: refs/heads/master@{#49491}
parent 83319454
......@@ -612,7 +612,7 @@ DEFINE_BOOL(write_protect_code_memory, false, "write protect code memory")
#endif
DEFINE_BOOL(concurrent_marking, V8_CONCURRENT_MARKING_BOOL,
"use concurrent marking")
DEFINE_BOOL(parallel_marking, false, "use parallel marking in atomic pause")
DEFINE_BOOL(parallel_marking, true, "use parallel marking in atomic pause")
DEFINE_IMPLICATION(parallel_marking, concurrent_marking)
DEFINE_BOOL(trace_concurrent_marking, false, "trace concurrent marking")
DEFINE_BOOL(minor_mc_parallel_marking, true,
......
......@@ -646,21 +646,26 @@ class ManualGCScope {
ManualGCScope()
: flag_concurrent_marking_(i::FLAG_concurrent_marking),
flag_concurrent_sweeping_(i::FLAG_concurrent_sweeping),
flag_stress_incremental_marking_(i::FLAG_stress_incremental_marking) {
flag_stress_incremental_marking_(i::FLAG_stress_incremental_marking),
flag_parallel_marking_(i::FLAG_parallel_marking) {
i::FLAG_concurrent_marking = false;
i::FLAG_concurrent_sweeping = false;
i::FLAG_stress_incremental_marking = false;
// Parallel marking has a dependency on concurrent marking.
i::FLAG_parallel_marking = false;
}
~ManualGCScope() {
i::FLAG_concurrent_marking = flag_concurrent_marking_;
i::FLAG_concurrent_sweeping = flag_concurrent_sweeping_;
i::FLAG_stress_incremental_marking = flag_stress_incremental_marking_;
i::FLAG_parallel_marking = flag_parallel_marking_;
}
private:
bool flag_concurrent_marking_;
bool flag_concurrent_sweeping_;
bool flag_stress_incremental_marking_;
bool flag_parallel_marking_;
};
// This is an abstract base class that can be overridden to implement a test
......
......@@ -46,9 +46,7 @@ HEAP_TEST(CompactionFullAbortedPage) {
// Disable concurrent sweeping to ensure memory is in an expected state, i.e.,
// we can reach the state of a half aborted page.
FLAG_concurrent_sweeping = false;
FLAG_concurrent_marking = false;
FLAG_stress_incremental_marking = false;
ManualGCScope manual_gc_scope;
FLAG_manual_evacuation_candidates_selection = true;
CcTest::InitializeVM();
Isolate* isolate = CcTest::i_isolate();
......@@ -91,9 +89,7 @@ HEAP_TEST(CompactionPartiallyAbortedPage) {
// Disable concurrent sweeping to ensure memory is in an expected state, i.e.,
// we can reach the state of a half aborted page.
FLAG_concurrent_sweeping = false;
FLAG_concurrent_marking = false;
FLAG_stress_incremental_marking = false;
ManualGCScope manual_gc_scope;
FLAG_manual_evacuation_candidates_selection = true;
const int objects_per_page = 10;
......@@ -168,9 +164,7 @@ HEAP_TEST(CompactionPartiallyAbortedPageIntraAbortedPointers) {
// Disable concurrent sweeping to ensure memory is in an expected state, i.e.,
// we can reach the state of a half aborted page.
FLAG_concurrent_sweeping = false;
FLAG_concurrent_marking = false;
FLAG_stress_incremental_marking = false;
ManualGCScope manual_gc_scope;
FLAG_manual_evacuation_candidates_selection = true;
const int objects_per_page = 10;
......@@ -258,9 +252,7 @@ HEAP_TEST(CompactionPartiallyAbortedPageWithStoreBufferEntries) {
// Disable concurrent sweeping to ensure memory is in an expected state, i.e.,
// we can reach the state of a half aborted page.
FLAG_concurrent_sweeping = false;
FLAG_concurrent_marking = false;
FLAG_stress_incremental_marking = false;
ManualGCScope manual_gc_scope;
FLAG_manual_evacuation_candidates_selection = true;
const int objects_per_page = 10;
......
......@@ -752,9 +752,8 @@ TEST(BytecodeArray) {
static const int kFrameSize = 32;
static const int kParameterCount = 2;
FLAG_concurrent_marking = false;
ManualGCScope manual_gc_scope;
FLAG_manual_evacuation_candidates_selection = true;
FLAG_stress_incremental_marking = false;
CcTest::InitializeVM();
Isolate* isolate = CcTest::i_isolate();
Heap* heap = isolate->heap();
......@@ -2878,16 +2877,16 @@ TEST(ReleaseOverReservedPages) {
// The optimizer can allocate stuff, messing up the test.
FLAG_opt = false;
FLAG_always_opt = false;
// Parallel compaction increases fragmentation, depending on how existing
// memory is distributed. Since this is non-deterministic because of
// concurrent sweeping, we disable it for this test.
FLAG_parallel_compaction = false;
FLAG_concurrent_marking = false;
// Concurrent sweeping adds non determinism, depending on when memory is
// available for further reuse.
FLAG_concurrent_sweeping = false;
// Fast evacuation of pages may result in a different page count in old space.
// - Parallel compaction increases fragmentation, depending on how existing
// memory is distributed. Since this is non-deterministic because of
// concurrent sweeping, we disable it for this test.
// - Concurrent sweeping adds non determinism, depending on when memory is
// available for further reuse.
// - Fast evacuation of pages may result in a different page count in old
// space.
ManualGCScope manual_gc_scope;
FLAG_page_promotion = false;
FLAG_parallel_compaction = false;
CcTest::InitializeVM();
Isolate* isolate = CcTest::i_isolate();
// If there's snapshot available, we don't know whether 20 small arrays will
......@@ -4457,7 +4456,7 @@ static void RequestInterrupt(const v8::FunctionCallbackInfo<v8::Value>& args) {
}
HEAP_TEST(Regress538257) {
FLAG_concurrent_marking = false;
ManualGCScope manual_gc_scope;
FLAG_manual_evacuation_candidates_selection = true;
v8::Isolate::CreateParams create_params;
// Set heap limits.
......@@ -5108,8 +5107,7 @@ TEST(SharedFunctionInfoIterator) {
}
HEAP_TEST(Regress587004) {
FLAG_concurrent_marking = false;
FLAG_concurrent_sweeping = false;
ManualGCScope manual_gc_scope;
#ifdef VERIFY_HEAP
FLAG_verify_heap = false;
#endif
......@@ -5151,8 +5149,7 @@ HEAP_TEST(Regress589413) {
FLAG_stress_compaction = true;
FLAG_manual_evacuation_candidates_selection = true;
FLAG_parallel_compaction = false;
FLAG_concurrent_marking = false;
FLAG_concurrent_sweeping = false;
ManualGCScope manual_gc_scope;
CcTest::InitializeVM();
v8::HandleScope scope(CcTest::isolate());
Heap* heap = CcTest::heap();
......@@ -5428,8 +5425,7 @@ TEST(Regress631969) {
if (!FLAG_incremental_marking) return;
FLAG_manual_evacuation_candidates_selection = true;
FLAG_parallel_compaction = false;
FLAG_concurrent_marking = false;
FLAG_concurrent_sweeping = false;
ManualGCScope manual_gc_scope;
CcTest::InitializeVM();
v8::HandleScope scope(CcTest::isolate());
Heap* heap = CcTest::heap();
......
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