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_GENERATOR_H_ | 5 #ifndef V8_INTERPRETER_BYTECODE_GENERATOR_H_ |
6 #define V8_INTERPRETER_BYTECODE_GENERATOR_H_ | 6 #define V8_INTERPRETER_BYTECODE_GENERATOR_H_ |
7 | 7 |
8 #include "src/ast.h" | 8 #include "src/ast.h" |
9 #include "src/interpreter/bytecode-array-builder.h" | 9 #include "src/interpreter/bytecode-array-builder.h" |
10 #include "src/interpreter/bytecodes.h" | 10 #include "src/interpreter/bytecodes.h" |
(...skipping 23 matching lines...) Expand all Loading... |
34 | 34 |
35 void MakeBytecodeBody(); | 35 void MakeBytecodeBody(); |
36 | 36 |
37 DEFINE_AST_VISITOR_SUBCLASS_MEMBERS(); | 37 DEFINE_AST_VISITOR_SUBCLASS_MEMBERS(); |
38 | 38 |
39 void VisitArithmeticExpression(BinaryOperation* binop); | 39 void VisitArithmeticExpression(BinaryOperation* binop); |
40 void VisitPropertyLoad(Register obj, Property* expr); | 40 void VisitPropertyLoad(Register obj, Property* expr); |
41 void VisitVariableLoad(Variable* variable, FeedbackVectorSlot slot); | 41 void VisitVariableLoad(Variable* variable, FeedbackVectorSlot slot); |
42 void VisitVariableAssignment(Variable* variable, FeedbackVectorSlot slot); | 42 void VisitVariableAssignment(Variable* variable, FeedbackVectorSlot slot); |
43 void VisitNewLocalFunctionContext(); | 43 void VisitNewLocalFunctionContext(); |
| 44 void VisitSetHomeObject(Register value, Register home_object, |
| 45 ObjectLiteralProperty* property, int slot_number = 0); |
| 46 void VisitObjectLiteralAccessor(Register home_object, |
| 47 ObjectLiteralProperty* property, |
| 48 Register value_out); |
44 | 49 |
45 // Dispatched from VisitUnaryOperation. | 50 // Dispatched from VisitUnaryOperation. |
46 void VisitVoid(UnaryOperation* expr); | 51 void VisitVoid(UnaryOperation* expr); |
47 void VisitTypeOf(UnaryOperation* expr); | 52 void VisitTypeOf(UnaryOperation* expr); |
48 void VisitNot(UnaryOperation* expr); | 53 void VisitNot(UnaryOperation* expr); |
49 | 54 |
50 inline BytecodeArrayBuilder* builder() { return &builder_; } | 55 inline BytecodeArrayBuilder* builder() { return &builder_; } |
51 | 56 |
52 inline Scope* scope() const { return scope_; } | 57 inline Scope* scope() const { return scope_; } |
53 inline void set_scope(Scope* scope) { scope_ = scope; } | 58 inline void set_scope(Scope* scope) { scope_ = scope; } |
(...skipping 19 matching lines...) Expand all Loading... |
73 ControlScope* control_scope_; | 78 ControlScope* control_scope_; |
74 | 79 |
75 Register current_context_; | 80 Register current_context_; |
76 }; | 81 }; |
77 | 82 |
78 } // namespace interpreter | 83 } // namespace interpreter |
79 } // namespace internal | 84 } // namespace internal |
80 } // namespace v8 | 85 } // namespace v8 |
81 | 86 |
82 #endif // V8_INTERPRETER_BYTECODE_GENERATOR_H_ | 87 #endif // V8_INTERPRETER_BYTECODE_GENERATOR_H_ |
OLD | NEW |