| Index: src/compiler/interpreter-assembler.cc
|
| diff --git a/src/compiler/interpreter-assembler.cc b/src/compiler/interpreter-assembler.cc
|
| index 4fd222c6aaa53eb47f3e1bb07c8a781aac7a74f6..e9c46895e7af041d9b9676435b6b760639d4c0ce 100644
|
| --- a/src/compiler/interpreter-assembler.cc
|
| +++ b/src/compiler/interpreter-assembler.cc
|
| @@ -584,6 +584,11 @@ Node* InterpreterAssembler::CallRuntime(Node* function_id, Node* first_arg,
|
| return CallN(descriptor, code_target, args);
|
| }
|
|
|
| +Node* InterpreterAssembler::CallRuntime(Runtime::FunctionId function_id) {
|
| + CallPrologue();
|
| + Node* return_val = raw_assembler_->CallRuntime0(function_id, GetContext());
|
| + return return_val;
|
| +}
|
|
|
| Node* InterpreterAssembler::CallRuntime(Runtime::FunctionId function_id,
|
| Node* arg1) {
|
| @@ -702,6 +707,20 @@ void InterpreterAssembler::DispatchTo(Node* new_bytecode_offset) {
|
| raw_assembler_->TailCallN(call_descriptor(), target_code_object, args);
|
| }
|
|
|
| +void InterpreterAssembler::StackCheck() {
|
| + RawMachineLabel ok, stack_guard;
|
| + Node* sp = raw_assembler_->LoadStackPointer();
|
| + Node* stack_limit = raw_assembler_->Load(
|
| + MachineType::Pointer(),
|
| + raw_assembler_->ExternalConstant(
|
| + ExternalReference::address_of_stack_limit(isolate())));
|
| + Node* condition = raw_assembler_->UintPtrGreaterThanOrEqual(sp, stack_limit);
|
| + raw_assembler_->Branch(condition, &ok, &stack_guard);
|
| + raw_assembler_->Bind(&stack_guard);
|
| + CallRuntime(Runtime::kStackGuard);
|
| + raw_assembler_->Goto(&ok);
|
| + raw_assembler_->Bind(&ok);
|
| +}
|
|
|
| void InterpreterAssembler::Abort(BailoutReason bailout_reason) {
|
| Node* abort_id = SmiTag(Int32Constant(bailout_reason));
|
|
|