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

Side by Side Diff: src/interpreter/bytecode-array-builder.h

Issue 1688283003: [Interpreter] Implements calls through CallICStub in the interpreter. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Fixes comments I missed in last patch. 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_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/interpreter/bytecode-register-allocator.h" 9 #include "src/interpreter/bytecode-register-allocator.h"
10 #include "src/interpreter/bytecodes.h" 10 #include "src/interpreter/bytecodes.h"
(...skipping 146 matching lines...) Expand 10 before | Expand all | Expand 10 after
157 // |context|. 157 // |context|.
158 BytecodeArrayBuilder& PushContext(Register context); 158 BytecodeArrayBuilder& PushContext(Register context);
159 159
160 // Pop the current context and replace with |context|. 160 // Pop the current context and replace with |context|.
161 BytecodeArrayBuilder& PopContext(Register context); 161 BytecodeArrayBuilder& PopContext(Register context);
162 162
163 // Call a JS function. The JSFunction or Callable to be called should be in 163 // Call a JS function. The JSFunction or Callable to be called should be in
164 // |callable|, the receiver should be in |receiver_args| and all subsequent 164 // |callable|, the receiver should be in |receiver_args| and all subsequent
165 // arguments should be in registers <receiver_args + 1> to 165 // arguments should be in registers <receiver_args + 1> to
166 // <receiver_args + receiver_arg_count - 1>. 166 // <receiver_args + receiver_arg_count - 1>.
167 // Call through CallICStub to get Typefeedback.
168 BytecodeArrayBuilder& CallIC(Register callable, Register receiver_args,
169 size_t receiver_arg_count, int feedback_slot);
170
171 // Call a JS function. The JSFunction or Callable to be called should be in
172 // |callable|, the receiver should be in |receiver_args| and all subsequent
173 // arguments should be in registers <receiver_args + 1> to
174 // <receiver_args + receiver_arg_count - 1>.
175 // Call without type feedback for eval and calls from lookup slots.
167 BytecodeArrayBuilder& Call(Register callable, Register receiver_args, 176 BytecodeArrayBuilder& Call(Register callable, Register receiver_args,
168 size_t receiver_arg_count, int feedback_slot); 177 size_t receiver_arg_count);
169 178
170 // Call the new operator. The |constructor| register is followed by 179 // Call the new operator. The |constructor| register is followed by
171 // |arg_count| consecutive registers containing arguments to be 180 // |arg_count| consecutive registers containing arguments to be
172 // applied to the constructor. 181 // applied to the constructor.
173 BytecodeArrayBuilder& New(Register constructor, Register first_arg, 182 BytecodeArrayBuilder& New(Register constructor, Register first_arg,
174 size_t arg_count); 183 size_t arg_count);
175 184
176 // Call the runtime function with |function_id|. The first argument should be 185 // Call the runtime function with |function_id|. The first argument should be
177 // in |first_arg| and all subsequent arguments should be in registers 186 // in |first_arg| and all subsequent arguments should be in registers
178 // <first_arg + 1> to <first_arg + arg_count - 1>. 187 // <first_arg + 1> to <first_arg + arg_count - 1>.
(...skipping 235 matching lines...) Expand 10 before | Expand all | Expand 10 after
414 size_t offset_; 423 size_t offset_;
415 424
416 friend class BytecodeArrayBuilder; 425 friend class BytecodeArrayBuilder;
417 }; 426 };
418 427
419 } // namespace interpreter 428 } // namespace interpreter
420 } // namespace internal 429 } // namespace internal
421 } // namespace v8 430 } // namespace v8
422 431
423 #endif // V8_INTERPRETER_BYTECODE_ARRAY_BUILDER_H_ 432 #endif // V8_INTERPRETER_BYTECODE_ARRAY_BUILDER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698