OLD | NEW |
1 // Copyright 2015 the V8 project authors. All rights reserved. | 1 // Copyright 2015 the V8 project authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "src/interpreter/interpreter-assembler.h" | 5 #include "src/interpreter/interpreter-assembler.h" |
6 | 6 |
7 #include <limits> | 7 #include <limits> |
8 #include <ostream> | 8 #include <ostream> |
9 | 9 |
10 #include "src/code-factory.h" | 10 #include "src/code-factory.h" |
(...skipping 830 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
841 } | 841 } |
842 | 842 |
843 Node* InterpreterAssembler::StackCheckTriggeredInterrupt() { | 843 Node* InterpreterAssembler::StackCheckTriggeredInterrupt() { |
844 Node* sp = LoadStackPointer(); | 844 Node* sp = LoadStackPointer(); |
845 Node* stack_limit = Load( | 845 Node* stack_limit = Load( |
846 MachineType::Pointer(), | 846 MachineType::Pointer(), |
847 ExternalConstant(ExternalReference::address_of_stack_limit(isolate()))); | 847 ExternalConstant(ExternalReference::address_of_stack_limit(isolate()))); |
848 return UintPtrLessThan(sp, stack_limit); | 848 return UintPtrLessThan(sp, stack_limit); |
849 } | 849 } |
850 | 850 |
| 851 Node* InterpreterAssembler::LoadOSRNestingLevel() { |
| 852 Node* offset = |
| 853 IntPtrConstant(BytecodeArray::kOSRNestingLevelOffset - kHeapObjectTag); |
| 854 return Load(MachineType::Int32(), BytecodeArrayTaggedPointer(), offset); |
| 855 } |
| 856 |
851 void InterpreterAssembler::Abort(BailoutReason bailout_reason) { | 857 void InterpreterAssembler::Abort(BailoutReason bailout_reason) { |
852 disable_stack_check_across_call_ = true; | 858 disable_stack_check_across_call_ = true; |
853 Node* abort_id = SmiTag(Int32Constant(bailout_reason)); | 859 Node* abort_id = SmiTag(Int32Constant(bailout_reason)); |
854 CallRuntime(Runtime::kAbort, GetContext(), abort_id); | 860 CallRuntime(Runtime::kAbort, GetContext(), abort_id); |
855 disable_stack_check_across_call_ = false; | 861 disable_stack_check_across_call_ = false; |
856 } | 862 } |
857 | 863 |
858 void InterpreterAssembler::AbortIfWordNotEqual(Node* lhs, Node* rhs, | 864 void InterpreterAssembler::AbortIfWordNotEqual(Node* lhs, Node* rhs, |
859 BailoutReason bailout_reason) { | 865 BailoutReason bailout_reason) { |
860 Label ok(this), abort(this, Label::kDeferred); | 866 Label ok(this), abort(this, Label::kDeferred); |
(...skipping 128 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
989 Goto(&loop); | 995 Goto(&loop); |
990 } | 996 } |
991 Bind(&done_loop); | 997 Bind(&done_loop); |
992 | 998 |
993 return array; | 999 return array; |
994 } | 1000 } |
995 | 1001 |
996 } // namespace interpreter | 1002 } // namespace interpreter |
997 } // namespace internal | 1003 } // namespace internal |
998 } // namespace v8 | 1004 } // namespace v8 |
OLD | NEW |