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_INTERPRETER_BYTECODE_ARRAY_BUILDER_H_ | 5 #ifndef V8_INTERPRETER_BYTECODE_ARRAY_BUILDER_H_ |
6 #define V8_INTERPRETER_BYTECODE_ARRAY_BUILDER_H_ | 6 #define V8_INTERPRETER_BYTECODE_ARRAY_BUILDER_H_ |
7 | 7 |
8 #include "src/ast/ast.h" | 8 #include "src/ast/ast.h" |
9 #include "src/base/compiler-specific.h" | 9 #include "src/base/compiler-specific.h" |
10 #include "src/globals.h" | 10 #include "src/globals.h" |
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
92 // Load the object at |slot_index| at |depth| in the context chain starting | 92 // Load the object at |slot_index| at |depth| in the context chain starting |
93 // with |context| into the accumulator. | 93 // with |context| into the accumulator. |
94 BytecodeArrayBuilder& LoadContextSlot(Register context, int slot_index, | 94 BytecodeArrayBuilder& LoadContextSlot(Register context, int slot_index, |
95 int depth); | 95 int depth); |
96 | 96 |
97 // Stores the object in the accumulator into |slot_index| at |depth| in the | 97 // Stores the object in the accumulator into |slot_index| at |depth| in the |
98 // context chain starting with |context|. | 98 // context chain starting with |context|. |
99 BytecodeArrayBuilder& StoreContextSlot(Register context, int slot_index, | 99 BytecodeArrayBuilder& StoreContextSlot(Register context, int slot_index, |
100 int depth); | 100 int depth); |
101 | 101 |
102 // Load from/store to the module variable with the given index. | |
rmcilroy
2016/11/03 13:58:06
nit - load from accumulator / store accumulator to
neis
2016/11/04 10:37:23
It loads from the module variable, not from the ac
| |
103 BytecodeArrayBuilder& LoadModuleVariable(int index); | |
104 BytecodeArrayBuilder& StoreModuleVariable(int index); | |
105 | |
102 // Register-accumulator transfers. | 106 // Register-accumulator transfers. |
103 BytecodeArrayBuilder& LoadAccumulatorWithRegister(Register reg); | 107 BytecodeArrayBuilder& LoadAccumulatorWithRegister(Register reg); |
104 BytecodeArrayBuilder& StoreAccumulatorInRegister(Register reg); | 108 BytecodeArrayBuilder& StoreAccumulatorInRegister(Register reg); |
105 | 109 |
106 // Register-register transfer. | 110 // Register-register transfer. |
107 BytecodeArrayBuilder& MoveRegister(Register from, Register to); | 111 BytecodeArrayBuilder& MoveRegister(Register from, Register to); |
108 | 112 |
109 // Named load property. | 113 // Named load property. |
110 BytecodeArrayBuilder& LoadNamedProperty(Register object, | 114 BytecodeArrayBuilder& LoadNamedProperty(Register object, |
111 const Handle<Name> name, | 115 const Handle<Name> name, |
(...skipping 291 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
403 static int const kNoFeedbackSlot = 0; | 407 static int const kNoFeedbackSlot = 0; |
404 | 408 |
405 DISALLOW_COPY_AND_ASSIGN(BytecodeArrayBuilder); | 409 DISALLOW_COPY_AND_ASSIGN(BytecodeArrayBuilder); |
406 }; | 410 }; |
407 | 411 |
408 } // namespace interpreter | 412 } // namespace interpreter |
409 } // namespace internal | 413 } // namespace internal |
410 } // namespace v8 | 414 } // namespace v8 |
411 | 415 |
412 #endif // V8_INTERPRETER_BYTECODE_ARRAY_BUILDER_H_ | 416 #endif // V8_INTERPRETER_BYTECODE_ARRAY_BUILDER_H_ |
OLD | NEW |