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 #ifndef V8_COMPILER_INTERPRETER_ASSEMBLER_H_ | 5 #ifndef V8_COMPILER_INTERPRETER_ASSEMBLER_H_ |
6 #define V8_COMPILER_INTERPRETER_ASSEMBLER_H_ | 6 #define V8_COMPILER_INTERPRETER_ASSEMBLER_H_ |
7 | 7 |
8 // Clients of this interface shouldn't depend on lots of compiler internals. | 8 // Clients of this interface shouldn't depend on lots of compiler internals. |
9 // Do not include anything from src/compiler here! | 9 // Do not include anything from src/compiler here! |
10 #include "src/allocation.h" | 10 #include "src/allocation.h" |
(...skipping 129 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
140 Node* CallRuntime(Runtime::FunctionId function_id, Node* arg1, Node* arg2); | 140 Node* CallRuntime(Runtime::FunctionId function_id, Node* arg1, Node* arg2); |
141 Node* CallRuntime(Runtime::FunctionId function_id, Node* arg1, Node* arg2, | 141 Node* CallRuntime(Runtime::FunctionId function_id, Node* arg1, Node* arg2, |
142 Node* arg3); | 142 Node* arg3); |
143 Node* CallRuntime(Runtime::FunctionId function_id, Node* arg1, Node* arg2, | 143 Node* CallRuntime(Runtime::FunctionId function_id, Node* arg1, Node* arg2, |
144 Node* arg3, Node* arg4); | 144 Node* arg3, Node* arg4); |
145 | 145 |
146 // Jump relative to the current bytecode by |jump_offset|. | 146 // Jump relative to the current bytecode by |jump_offset|. |
147 void Jump(Node* jump_offset); | 147 void Jump(Node* jump_offset); |
148 | 148 |
149 // Jump relative to the current bytecode by |jump_offset| if the | 149 // Jump relative to the current bytecode by |jump_offset| if the |
| 150 // |condition| is true. Helper function for JumpIfWordEqual and |
| 151 // JumpIfWordNotEqual. |
| 152 void JumpConditional(Node* condition, Node* jump_offset); |
| 153 |
| 154 // Jump relative to the current bytecode by |jump_offset| if the |
150 // word values |lhs| and |rhs| are equal. | 155 // word values |lhs| and |rhs| are equal. |
151 void JumpIfWordEqual(Node* lhs, Node* rhs, Node* jump_offset); | 156 void JumpIfWordEqual(Node* lhs, Node* rhs, Node* jump_offset); |
152 | 157 |
| 158 // Jump relative to the current bytecode by |jump_offset| if the |
| 159 // word values |lhs| and |rhs| are not equal. |
| 160 void JumpIfWordNotEqual(Node* lhs, Node* rhs, Node* jump_offset); |
| 161 |
153 // Returns from the function. | 162 // Returns from the function. |
154 void Return(); | 163 void Return(); |
155 | 164 |
156 // Dispatch to the bytecode. | 165 // Dispatch to the bytecode. |
157 void Dispatch(); | 166 void Dispatch(); |
158 | 167 |
159 // Abort with the given bailout reason. | 168 // Abort with the given bailout reason. |
160 void Abort(BailoutReason bailout_reason); | 169 void Abort(BailoutReason bailout_reason); |
161 | 170 |
162 protected: | 171 protected: |
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
219 bool code_generated_; | 228 bool code_generated_; |
220 | 229 |
221 DISALLOW_COPY_AND_ASSIGN(InterpreterAssembler); | 230 DISALLOW_COPY_AND_ASSIGN(InterpreterAssembler); |
222 }; | 231 }; |
223 | 232 |
224 } // namespace compiler | 233 } // namespace compiler |
225 } // namespace internal | 234 } // namespace internal |
226 } // namespace v8 | 235 } // namespace v8 |
227 | 236 |
228 #endif // V8_COMPILER_INTERPRETER_ASSEMBLER_H_ | 237 #endif // V8_COMPILER_INTERPRETER_ASSEMBLER_H_ |
OLD | NEW |