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

Unified Diff: src/compiler/bytecode-graph-builder.cc

Issue 2639233002: [Turbofan] Add CallFunctionWithSpread JSOperator. (Closed)
Patch Set: Set CL dependency to bytecode CL Created 3 years, 11 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | src/compiler/js-generic-lowering.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/compiler/bytecode-graph-builder.cc
diff --git a/src/compiler/bytecode-graph-builder.cc b/src/compiler/bytecode-graph-builder.cc
index 5b2c8805aa94dcba702b7fccdea7e0f5a996c032..5a596e2f45c612a47bc3b14b367a2dad94f6968c 100644
--- a/src/compiler/bytecode-graph-builder.cc
+++ b/src/compiler/bytecode-graph-builder.cc
@@ -1273,6 +1273,16 @@ void BytecodeGraphBuilder::VisitCall() {
BuildCall(TailCallMode::kDisallow, ConvertReceiverMode::kAny);
}
+void BytecodeGraphBuilder::VisitCallWithSpread() {
+ PrepareEagerCheckpoint();
+ interpreter::Register first_arg = bytecode_iterator().GetRegisterOperand(0);
+ size_t arg_count = bytecode_iterator().GetRegisterCountOperand(1);
+ const Operator* op =
+ javascript()->CallFunctionWithSpread(static_cast<int>(arg_count));
+ Node* value = ProcessCallRuntimeArguments(op, first_arg, arg_count);
+ environment()->BindAccumulator(value, Environment::kAttachFrameState);
+}
+
void BytecodeGraphBuilder::VisitCallProperty() {
BuildCall(TailCallMode::kDisallow, ConvertReceiverMode::kNotNullOrUndefined);
}
@@ -1353,16 +1363,6 @@ Node* BytecodeGraphBuilder::ProcessCallNewWithSpreadArguments(
return value;
}
-void BytecodeGraphBuilder::VisitCallWithSpread() {
- PrepareEagerCheckpoint();
- interpreter::Register first_arg = bytecode_iterator().GetRegisterOperand(0);
- size_t arg_count = bytecode_iterator().GetRegisterCountOperand(1);
- const Operator* call =
- javascript()->CallRuntime(Runtime::kCallWithSpread, arg_count);
- Node* value = ProcessCallRuntimeArguments(call, first_arg, arg_count);
- environment()->BindAccumulator(value, Environment::kAttachFrameState);
-}
-
void BytecodeGraphBuilder::VisitNewWithSpread() {
PrepareEagerCheckpoint();
interpreter::Register callee_reg = bytecode_iterator().GetRegisterOperand(0);
« no previous file with comments | « no previous file | src/compiler/js-generic-lowering.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698