Index: src/compiler/ppc/code-generator-ppc.cc |
diff --git a/src/compiler/ppc/code-generator-ppc.cc b/src/compiler/ppc/code-generator-ppc.cc |
index 34a66fd6bd0713058963a30d04b2c637feb8d8dd..4a4bb8e59cb5fc8ed4eaa2215ee55eaa6a8a05c2 100644 |
--- a/src/compiler/ppc/code-generator-ppc.cc |
+++ b/src/compiler/ppc/code-generator-ppc.cc |
@@ -727,7 +727,8 @@ void CodeGenerator::AssemblePopArgumentsAdaptorFrame(Register args_reg, |
} |
// Assembles an instruction after register allocation, producing machine code. |
-void CodeGenerator::AssembleArchInstruction(Instruction* instr) { |
+CodeGenerator::CodeGenResult CodeGenerator::AssembleArchInstruction( |
+ Instruction* instr) { |
PPCOperandConverter i(this, instr); |
ArchOpcode opcode = ArchOpcodeField::decode(instr->opcode()); |
@@ -868,7 +869,9 @@ void CodeGenerator::AssembleArchInstruction(Instruction* instr) { |
BuildTranslation(instr, -1, 0, OutputFrameStateCombine::Ignore()); |
Deoptimizer::BailoutType bailout_type = |
Deoptimizer::BailoutType(MiscField::decode(instr->opcode())); |
- AssembleDeoptimizerCall(deopt_state_id, bailout_type); |
+ CodeGenResult result = |
+ AssembleDeoptimizerCall(deopt_state_id, bailout_type); |
+ if (result != kSuccess) return result; |
break; |
} |
case kArchRet: |
@@ -1611,6 +1614,7 @@ void CodeGenerator::AssembleArchInstruction(Instruction* instr) { |
UNREACHABLE(); |
break; |
} |
+ return kSuccess; |
} // NOLINT(readability/fn_size) |
@@ -1730,15 +1734,16 @@ void CodeGenerator::AssembleArchTableSwitch(Instruction* instr) { |
__ Jump(kScratchReg); |
} |
- |
-void CodeGenerator::AssembleDeoptimizerCall( |
+CodeGenerator::CodeGenResult CodeGenerator::AssembleDeoptimizerCall( |
int deoptimization_id, Deoptimizer::BailoutType bailout_type) { |
Address deopt_entry = Deoptimizer::GetDeoptimizationEntry( |
isolate(), deoptimization_id, bailout_type); |
// TODO(turbofan): We should be able to generate better code by sharing the |
// actual final call site and just bl'ing to it here, similar to what we do |
// in the lithium backend. |
+ if (deopt_entry == nullptr) return kTooManyDeoptimizationBailouts; |
__ Call(deopt_entry, RelocInfo::RUNTIME_ENTRY); |
+ return kSuccess; |
} |
void CodeGenerator::FinishFrame(Frame* frame) { |