Index: src/compiler/pipeline.cc |
diff --git a/src/compiler/pipeline.cc b/src/compiler/pipeline.cc |
index 50846d6e81f6c03c69fa4e2b40c33f8e0b93a96e..be16940ad17cab134299c03765e89c5665ef74b6 100644 |
--- a/src/compiler/pipeline.cc |
+++ b/src/compiler/pipeline.cc |
@@ -1002,8 +1002,9 @@ struct OptimizeMovesPhase { |
struct FrameElisionPhase { |
static const char* phase_name() { return "frame elision"; } |
- void Run(PipelineData* data, Zone* temp_zone) { |
- FrameElider(data->sequence()).Run(); |
+ void Run(PipelineData* data, Zone* temp_zone, |
+ const CallDescriptor* descriptor) { |
+ FrameElider(data->sequence()).Run(descriptor); |
} |
}; |
@@ -1373,11 +1374,7 @@ Handle<Code> Pipeline::ScheduleAndGenerateCode( |
BeginPhaseKind("code generation"); |
// TODO(mtrofin): move this off to the register allocator. |
bool generate_frame_at_start = |
- !FLAG_turbo_frame_elision || !data_->info()->IsStub() || |
- !data_->frame()->needs_frame() || |
- data_->sequence()->instruction_blocks().front()->needs_frame() || |
- linkage.GetIncomingDescriptor()->CalleeSavedFPRegisters() != 0 || |
- linkage.GetIncomingDescriptor()->CalleeSavedRegisters() != 0; |
+ data_->sequence()->instruction_blocks().front()->must_construct_frame(); |
// Optimimize jumps. |
if (FLAG_turbo_jt) { |
Run<JumpThreadingPhase>(generate_frame_at_start); |
@@ -1485,10 +1482,9 @@ void Pipeline::AllocateRegisters(const RegisterConfiguration* config, |
} |
// We plan to enable frame elision only for stubs and bytecode handlers. |
- if (FLAG_turbo_frame_elision && info()->IsStub()) { |
- Run<LocateSpillSlotsPhase>(); |
- Run<FrameElisionPhase>(); |
- } |
+ |
+ Run<LocateSpillSlotsPhase>(); |
+ Run<FrameElisionPhase>(descriptor); |
Run<AssignSpillSlotsPhase>(); |