diff --git a/src/flag-definitions.h b/src/flag-definitions.h index da41303e95..5ee8a702b0 100644 --- a/src/flag-definitions.h +++ b/src/flag-definitions.h @@ -439,12 +439,8 @@ DEFINE_BOOL(print_deopt_stress, false, "print number of possible deopt points") // Flags for TurboFan. DEFINE_BOOL(turbo_sp_frame_access, false, "use stack pointer-relative access to frame wherever possible") -DEFINE_BOOL(turbo_preprocess_ranges, true, - "run pre-register allocation heuristics") DEFINE_BOOL(turbo_control_flow_aware_allocation, false, "consider control flow while allocating registers") -DEFINE_NEG_IMPLICATION(turbo_control_flow_aware_allocation, - turbo_preprocess_ranges) DEFINE_STRING(turbo_filter, "*", "optimization filter for TurboFan compiler") DEFINE_BOOL(trace_turbo, false, "trace generated TurboFan IR") diff --git a/src/optimized-compilation-info.cc b/src/optimized-compilation-info.cc index 9c0fdd5448..f6333e4a58 100644 --- a/src/optimized-compilation-info.cc +++ b/src/optimized-compilation-info.cc @@ -91,8 +91,7 @@ void OptimizedCompilationInfo::ConfigureFlags() { if (FLAG_turbo_control_flow_aware_allocation) { MarkAsTurboControlFlowAwareAllocation(); - } - if (FLAG_turbo_preprocess_ranges) { + } else { MarkAsTurboPreprocessRanges(); } } diff --git a/test/unittests/compiler/regalloc/register-allocator-unittest.cc b/test/unittests/compiler/regalloc/register-allocator-unittest.cc index 76fc39e2f6..bf53812bb6 100644 --- a/test/unittests/compiler/regalloc/register-allocator-unittest.cc +++ b/test/unittests/compiler/regalloc/register-allocator-unittest.cc @@ -625,22 +625,18 @@ TEST_F(RegisterAllocatorTest, SingleDeferredBlockSpill) { const int var_def_index = 1; const int call_index = 3; - const bool spill_in_deferred = - FLAG_turbo_preprocess_ranges || FLAG_turbo_control_flow_aware_allocation; - int expect_no_moves = spill_in_deferred ? var_def_index : call_index; - int expect_spill_move = spill_in_deferred ? call_index : var_def_index; - // We should have no parallel moves at the "expect_no_moves" position. + // We should have no parallel moves at the "var_def_index" position. EXPECT_EQ( - 0, GetParallelMoveCount(expect_no_moves, Instruction::START, sequence())); + 0, GetParallelMoveCount(var_def_index, Instruction::START, sequence())); - // The spill should be performed at the position expect_spill_move. - EXPECT_TRUE(IsParallelMovePresent(expect_spill_move, Instruction::START, - sequence(), Reg(0), Slot(0))); + // The spill should be performed at the position "call_index". + EXPECT_TRUE(IsParallelMovePresent(call_index, Instruction::START, sequence(), + Reg(0), Slot(0))); } TEST_F(RegisterAllocatorTest, MultipleDeferredBlockSpills) { - if (!FLAG_turbo_preprocess_ranges) return; + if (FLAG_turbo_control_flow_aware_allocation) return; StartBlock(); // B0 auto var1 = EmitOI(Reg(0));