Index: src/compiler/mips64/code-generator-mips64.cc |
diff --git a/src/compiler/mips64/code-generator-mips64.cc b/src/compiler/mips64/code-generator-mips64.cc |
index 5f789b79750d2677ff1da43a2b5c354238900817..c305b688d653d32b4456425a34caf0a4b8e2f164 100644 |
--- a/src/compiler/mips64/code-generator-mips64.cc |
+++ b/src/compiler/mips64/code-generator-mips64.cc |
@@ -768,8 +768,10 @@ |
case kArchDeoptimize: { |
int deopt_state_id = |
BuildTranslation(instr, -1, 0, OutputFrameStateCombine::Ignore()); |
- CodeGenResult result = |
- AssembleDeoptimizerCall(deopt_state_id, current_source_position_); |
+ Deoptimizer::BailoutType bailout_type = |
+ Deoptimizer::BailoutType(MiscField::decode(instr->opcode())); |
+ CodeGenResult result = AssembleDeoptimizerCall( |
+ deopt_state_id, bailout_type, current_source_position_); |
if (result != kSuccess) return result; |
break; |
} |
@@ -2329,16 +2331,13 @@ |
} |
CodeGenerator::CodeGenResult CodeGenerator::AssembleDeoptimizerCall( |
- int deoptimization_id, SourcePosition pos) { |
- DeoptimizeKind deoptimization_kind = GetDeoptimizationKind(deoptimization_id); |
- DeoptimizeReason deoptimization_reason = |
- GetDeoptimizationReason(deoptimization_id); |
- Deoptimizer::BailoutType bailout_type = |
- deoptimization_kind == DeoptimizeKind::kSoft ? Deoptimizer::SOFT |
- : Deoptimizer::EAGER; |
+ int deoptimization_id, Deoptimizer::BailoutType bailout_type, |
+ SourcePosition pos) { |
Address deopt_entry = Deoptimizer::GetDeoptimizationEntry( |
isolate(), deoptimization_id, bailout_type); |
if (deopt_entry == nullptr) return kTooManyDeoptimizationBailouts; |
+ DeoptimizeReason deoptimization_reason = |
+ GetDeoptimizationReason(deoptimization_id); |
__ RecordDeoptReason(deoptimization_reason, pos, deoptimization_id); |
__ Call(deopt_entry, RelocInfo::RUNTIME_ENTRY); |
return kSuccess; |