Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(726)

Side by Side Diff: src/interpreter/bytecode-generator.h

Issue 1689573004: [interpreter] Support for ES6 super keyword. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Update test262.status. Created 4 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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/ast.h" 8 #include "src/ast/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 49 matching lines...) Expand 10 before | Expand all | Expand 10 after
60 void VisitDelete(UnaryOperation* expr); 60 void VisitDelete(UnaryOperation* expr);
61 61
62 // Used by flow control routines to evaluate loop condition. 62 // Used by flow control routines to evaluate loop condition.
63 void VisitCondition(Expression* expr); 63 void VisitCondition(Expression* expr);
64 64
65 // Helper visitors which perform common operations. 65 // Helper visitors which perform common operations.
66 Register VisitArguments(ZoneList<Expression*>* arguments); 66 Register VisitArguments(ZoneList<Expression*>* arguments);
67 67
68 void VisitPropertyLoad(Register obj, Property* expr); 68 void VisitPropertyLoad(Register obj, Property* expr);
69 void VisitPropertyLoadForAccumulator(Register obj, Property* expr); 69 void VisitPropertyLoadForAccumulator(Register obj, Property* expr);
70 70 void VisitKeyedSuperPropertyLoad(Property* property, Register receiver_out);
rmcilroy 2016/02/11 15:25:49 I think these could do with a comment to specify w
oth 2016/02/12 14:12:53 Done.
71 void VisitNamedSuperPropertyLoad(Property* property, Register receiver_out);
71 void VisitVariableLoad(Variable* variable, FeedbackVectorSlot slot, 72 void VisitVariableLoad(Variable* variable, FeedbackVectorSlot slot,
72 TypeofMode typeof_mode = NOT_INSIDE_TYPEOF); 73 TypeofMode typeof_mode = NOT_INSIDE_TYPEOF);
73 void VisitVariableLoadForAccumulatorValue( 74 void VisitVariableLoadForAccumulatorValue(
74 Variable* variable, FeedbackVectorSlot slot, 75 Variable* variable, FeedbackVectorSlot slot,
75 TypeofMode typeof_mode = NOT_INSIDE_TYPEOF); 76 TypeofMode typeof_mode = NOT_INSIDE_TYPEOF);
76 MUST_USE_RESULT Register 77 MUST_USE_RESULT Register
77 VisitVariableLoadForRegisterValue(Variable* variable, FeedbackVectorSlot slot, 78 VisitVariableLoadForRegisterValue(Variable* variable, FeedbackVectorSlot slot,
78 TypeofMode typeof_mode = NOT_INSIDE_TYPEOF); 79 TypeofMode typeof_mode = NOT_INSIDE_TYPEOF);
79 void VisitVariableAssignment(Variable* variable, Token::Value op, 80 void VisitVariableAssignment(Variable* variable, Token::Value op,
80 FeedbackVectorSlot slot); 81 FeedbackVectorSlot slot);
82 void BuildKeyedSuperLoad(Register receiver, Register home_object,
83 Register key);
84 void BuildKeyedSuperStore(Register receiver, Register home_object,
85 Register key);
86 void BuildNamedSuperLoad(Register receiver, Register home_object,
87 Handle<Name> name);
88 void BuildNamedSuperStore(Register receiver, Register home_object,
89 Handle<Name> name);
81 void BuildThrowIfHole(Handle<String> name); 90 void BuildThrowIfHole(Handle<String> name);
82 void BuildThrowIfNotHole(Handle<String> name); 91 void BuildThrowIfNotHole(Handle<String> name);
83 void BuildThrowReassignConstant(Handle<String> name); 92 void BuildThrowReassignConstant(Handle<String> name);
84 void BuildHoleCheckForVariableLoad(VariableMode mode, Handle<String> name); 93 void BuildHoleCheckForVariableLoad(VariableMode mode, Handle<String> name);
85 void BuildHoleCheckForVariableAssignment(Variable* variable, Token::Value op); 94 void BuildHoleCheckForVariableAssignment(Variable* variable, Token::Value op);
86 95
87 void VisitArgumentsObject(Variable* variable); 96 void VisitArgumentsObject(Variable* variable);
88 void VisitRestArgumentsArray(Variable* rest); 97 void VisitRestArgumentsArray(Variable* rest);
98 void VisitCallSuper(Call* call);
89 void VisitClassLiteralContents(ClassLiteral* expr); 99 void VisitClassLiteralContents(ClassLiteral* expr);
90 void VisitClassLiteralForRuntimeDefinition(ClassLiteral* expr); 100 void VisitClassLiteralForRuntimeDefinition(ClassLiteral* expr);
91 void VisitClassLiteralProperties(ClassLiteral* expr, Register literal, 101 void VisitClassLiteralProperties(ClassLiteral* expr, Register literal,
92 Register prototype); 102 Register prototype);
93 void VisitClassLiteralStaticPrototypeWithComputedName(Register name); 103 void VisitClassLiteralStaticPrototypeWithComputedName(Register name);
94 void VisitThisFunctionVariable(Variable* variable); 104 void VisitThisFunctionVariable(Variable* variable);
95 void VisitNewTargetVariable(Variable* variable); 105 void VisitNewTargetVariable(Variable* variable);
96 void VisitNewLocalFunctionContext(); 106 void VisitNewLocalFunctionContext();
97 void VisitBuildLocalActivationContext(); 107 void VisitBuildLocalActivationContext();
98 void VisitBlockDeclarationsAndStatements(Block* stmt); 108 void VisitBlockDeclarationsAndStatements(Block* stmt);
(...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after
170 ContextScope* execution_context_; 180 ContextScope* execution_context_;
171 ExpressionResultScope* execution_result_; 181 ExpressionResultScope* execution_result_;
172 RegisterAllocationScope* register_allocator_; 182 RegisterAllocationScope* register_allocator_;
173 }; 183 };
174 184
175 } // namespace interpreter 185 } // namespace interpreter
176 } // namespace internal 186 } // namespace internal
177 } // namespace v8 187 } // namespace v8
178 188
179 #endif // V8_INTERPRETER_BYTECODE_GENERATOR_H_ 189 #endif // V8_INTERPRETER_BYTECODE_GENERATOR_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698