| Index: src/interpreter/bytecode-generator.cc
|
| diff --git a/src/interpreter/bytecode-generator.cc b/src/interpreter/bytecode-generator.cc
|
| index 866351e9d967f33fd257ac62c7a67aafcbdf4010..c13ceac22297a399db57ebf43e9763ba718acb51 100644
|
| --- a/src/interpreter/bytecode-generator.cc
|
| +++ b/src/interpreter/bytecode-generator.cc
|
| @@ -657,13 +657,7 @@ void BytecodeGenerator::BuildIndexedJump(Register index, size_t start_index,
|
| .JumpIfTrue(&(targets[i]));
|
| }
|
|
|
| - RegisterAllocationScope register_scope(this);
|
| - Register reason = register_allocator()->NewRegister();
|
| - BailoutReason bailout_reason = BailoutReason::kInvalidJumpTableIndex;
|
| - builder()
|
| - ->LoadLiteral(Smi::FromInt(static_cast<int>(bailout_reason)))
|
| - .StoreAccumulatorInRegister(reason)
|
| - .CallRuntime(Runtime::kAbort, reason, 1);
|
| + BuildAbort(BailoutReason::kInvalidJumpTableIndex);
|
| }
|
|
|
| void BytecodeGenerator::VisitIterationHeader(IterationStatement* stmt,
|
| @@ -1959,6 +1953,15 @@ void BytecodeGenerator::BuildKeyedSuperPropertyStore(Register receiver,
|
| builder()->CallRuntime(function_id, receiver, 4);
|
| }
|
|
|
| +void BytecodeGenerator::BuildAbort(BailoutReason bailout_reason) {
|
| + RegisterAllocationScope register_scope(this);
|
| + Register reason = register_allocator()->NewRegister();
|
| + builder()
|
| + ->LoadLiteral(Smi::FromInt(static_cast<int>(bailout_reason)))
|
| + .StoreAccumulatorInRegister(reason)
|
| + .CallRuntime(Runtime::kAbort, reason, 1);
|
| +}
|
| +
|
| void BytecodeGenerator::BuildThrowReferenceError(Handle<String> name) {
|
| RegisterAllocationScope register_scope(this);
|
| Register name_reg = register_allocator()->NewRegister();
|
|
|