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

Unified Diff: src/fast-accessor-assembler.cc

Issue 2577913003: [turbofan] Combine family of CallStub() methods into single implementation. (Closed)
Patch Set: Addressing comments Created 4 years 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 | « src/compiler/code-assembler.cc ('k') | src/interpreter/interpreter.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/fast-accessor-assembler.cc
diff --git a/src/fast-accessor-assembler.cc b/src/fast-accessor-assembler.cc
index a1bd12d3b8d249d5ce56623505887c3eb5124717..e09db746664cdcb716bb641969c91db6cac1797e 100644
--- a/src/fast-accessor-assembler.cc
+++ b/src/fast-accessor-assembler.cc
@@ -192,23 +192,13 @@ FastAccessorAssembler::ValueId FastAccessorAssembler::Call(
Node* context = assembler_->Parameter(kContextParameter);
Node* target = assembler_->HeapConstant(stub.GetCode());
- int param_count = descriptor.GetParameterCount();
- Node** args = zone()->NewArray<Node*>(param_count + 1 + kJSParameterCount);
- // Stub/register parameters:
- args[0] = assembler_->UndefinedConstant(); // callee (there's no JSFunction)
- args[1] = assembler_->UndefinedConstant(); // call_data (undefined)
- args[2] = assembler_->Parameter(0); // receiver (same as holder in this case)
- args[3] = assembler_->ExternalConstant(callback); // API callback function
-
- // JS arguments, on stack:
- args[4] = FromId(arg);
-
- // Context.
- args[5] = context;
-
- Node* call =
- assembler_->CallStubN(descriptor, kJSParameterCount, target, args);
-
+ Node* call = assembler_->CallStub(
+ descriptor, target, context,
+ assembler_->UndefinedConstant(), // callee (there's no JSFunction)
+ assembler_->UndefinedConstant(), // call_data (undefined)
+ assembler_->Parameter(0), // receiver (same as holder in this case)
+ assembler_->ExternalConstant(callback), // API callback function
+ FromId(arg)); // JS argument, on stack
return FromRaw(call);
}
« no previous file with comments | « src/compiler/code-assembler.cc ('k') | src/interpreter/interpreter.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698