Chromium Code Reviews| 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 49 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 60 void SetContext(Node* value); | 60 void SetContext(Node* value); |
| 61 | 61 |
| 62 // Loads from and stores to the interpreter register file. | 62 // Loads from and stores to the interpreter register file. |
| 63 Node* LoadRegister(int offset); | 63 Node* LoadRegister(int offset); |
| 64 Node* LoadRegister(interpreter::Register reg); | 64 Node* LoadRegister(interpreter::Register reg); |
| 65 Node* LoadRegister(Node* reg_index); | 65 Node* LoadRegister(Node* reg_index); |
| 66 Node* StoreRegister(Node* value, int offset); | 66 Node* StoreRegister(Node* value, int offset); |
| 67 Node* StoreRegister(Node* value, interpreter::Register reg); | 67 Node* StoreRegister(Node* value, interpreter::Register reg); |
| 68 Node* StoreRegister(Node* value, Node* reg_index); | 68 Node* StoreRegister(Node* value, Node* reg_index); |
| 69 | 69 |
| 70 // Returns the next consecutive register. | |
| 71 Node* NextRegister(Node* reg_index); | |
| 72 | |
| 70 // Returns the location in memory of the register |reg_index| in the | 73 // Returns the location in memory of the register |reg_index| in the |
| 71 // interpreter register file. | 74 // interpreter register file. |
| 72 Node* RegisterLocation(Node* reg_index); | 75 Node* RegisterLocation(Node* reg_index); |
| 73 | 76 |
| 74 // Constants. | 77 // Constants. |
| 75 Node* Int32Constant(int value); | 78 Node* Int32Constant(int value); |
| 76 Node* IntPtrConstant(intptr_t value); | 79 Node* IntPtrConstant(intptr_t value); |
| 77 Node* NumberConstant(double value); | 80 Node* NumberConstant(double value); |
| 78 Node* HeapConstant(Handle<HeapObject> object); | 81 Node* HeapConstant(Handle<HeapObject> object); |
| 79 Node* BooleanConstant(bool value); | 82 Node* BooleanConstant(bool value); |
| (...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 123 | 126 |
| 124 // Call an IC code stub. | 127 // Call an IC code stub. |
| 125 Node* CallIC(CallInterfaceDescriptor descriptor, Node* target, Node* arg1, | 128 Node* CallIC(CallInterfaceDescriptor descriptor, Node* target, Node* arg1, |
| 126 Node* arg2, Node* arg3); | 129 Node* arg2, Node* arg3); |
| 127 Node* CallIC(CallInterfaceDescriptor descriptor, Node* target, Node* arg1, | 130 Node* CallIC(CallInterfaceDescriptor descriptor, Node* target, Node* arg1, |
| 128 Node* arg2, Node* arg3, Node* arg4); | 131 Node* arg2, Node* arg3, Node* arg4); |
| 129 Node* CallIC(CallInterfaceDescriptor descriptor, Node* target, Node* arg1, | 132 Node* CallIC(CallInterfaceDescriptor descriptor, Node* target, Node* arg1, |
| 130 Node* arg2, Node* arg3, Node* arg4, Node* arg5); | 133 Node* arg2, Node* arg3, Node* arg4, Node* arg5); |
| 131 | 134 |
| 132 // Call runtime function. | 135 // Call runtime function. |
| 136 Node* CallRuntime(CallDescriptor* descriptor, Handle<Code> call_stub, | |
| 137 Node* function_id, Node* first_arg, Node* arg_count); | |
| 133 Node* CallRuntime(Node* function_id, Node* first_arg, Node* arg_count); | 138 Node* CallRuntime(Node* function_id, Node* first_arg, Node* arg_count); |
|
Michael Starzinger
2016/01/07 17:21:28
suggestion: Likewise to code-factory, can we pass
rmcilroy
2016/01/08 14:15:07
Done.
| |
| 139 Node* CallRuntimePair(Node* function_id, Node* first_arg, Node* arg_count); | |
| 134 Node* CallRuntime(Runtime::FunctionId function_id, Node* arg1); | 140 Node* CallRuntime(Runtime::FunctionId function_id, Node* arg1); |
| 135 Node* CallRuntime(Runtime::FunctionId function_id, Node* arg1, Node* arg2); | 141 Node* CallRuntime(Runtime::FunctionId function_id, Node* arg1, Node* arg2); |
| 136 Node* CallRuntime(Runtime::FunctionId function_id, Node* arg1, Node* arg2, | 142 Node* CallRuntime(Runtime::FunctionId function_id, Node* arg1, Node* arg2, |
| 137 Node* arg3, Node* arg4); | 143 Node* arg3, Node* arg4); |
| 138 | 144 |
| 139 // Jump relative to the current bytecode by |jump_offset|. | 145 // Jump relative to the current bytecode by |jump_offset|. |
| 140 void Jump(Node* jump_offset); | 146 void Jump(Node* jump_offset); |
| 141 | 147 |
| 142 // Jump relative to the current bytecode by |jump_offset| if the | 148 // Jump relative to the current bytecode by |jump_offset| if the |
| 143 // word values |lhs| and |rhs| are equal. | 149 // word values |lhs| and |rhs| are equal. |
| (...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 211 bool code_generated_; | 217 bool code_generated_; |
| 212 | 218 |
| 213 DISALLOW_COPY_AND_ASSIGN(InterpreterAssembler); | 219 DISALLOW_COPY_AND_ASSIGN(InterpreterAssembler); |
| 214 }; | 220 }; |
| 215 | 221 |
| 216 } // namespace compiler | 222 } // namespace compiler |
| 217 } // namespace internal | 223 } // namespace internal |
| 218 } // namespace v8 | 224 } // namespace v8 |
| 219 | 225 |
| 220 #endif // V8_COMPILER_INTERPRETER_ASSEMBLER_H_ | 226 #endif // V8_COMPILER_INTERPRETER_ASSEMBLER_H_ |
| OLD | NEW |