Index: src/x64/lithium-codegen-x64.cc |
=================================================================== |
--- src/x64/lithium-codegen-x64.cc (revision 6473) |
+++ src/x64/lithium-codegen-x64.cc (working copy) |
@@ -374,20 +374,16 @@ |
// Create the environment to bailout to. If the call has side effects |
// execution has to continue after the call otherwise execution can continue |
// from a previous bailout point repeating the call. |
- LEnvironment* lazy_deoptimization_environment; |
- ASSERT(!instr->IsControl()); |
- ASSERT(instructions_->at(current_instruction_ + 1)->IsGap()); |
- LInstruction* next_instr = instructions_->at(current_instruction_ + 2); |
- if (next_instr->IsLazyBailout()) { |
- ASSERT(next_instr->HasEnvironment()); |
- lazy_deoptimization_environment = next_instr->environment(); |
+ LEnvironment* deoptimization_environment; |
+ if (instr->HasDeoptimizationEnvironment()) { |
+ deoptimization_environment = instr->deoptimization_environment(); |
} else { |
- lazy_deoptimization_environment = instr->environment(); |
+ deoptimization_environment = instr->environment(); |
} |
- RegisterEnvironmentForDeoptimization(lazy_deoptimization_environment); |
+ RegisterEnvironmentForDeoptimization(deoptimization_environment); |
RecordSafepoint(instr->pointer_map(), |
- lazy_deoptimization_environment->deoptimization_index()); |
+ deoptimization_environment->deoptimization_index()); |
} |