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

Unified Diff: src/runtime/runtime-array.cc

Issue 1987183002: [stubs] Convert Internal/ArraySingleArgumentsConstructor to a TurboFan stub (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Review feedback Created 4 years, 7 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 | « src/runtime/runtime.h ('k') | src/x64/code-stubs-x64.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/runtime/runtime-array.cc
diff --git a/src/runtime/runtime-array.cc b/src/runtime/runtime-array.cc
index 519df7784bca7a1506229f1f2da7491830beb5c9..05c7d92283b1106f074265cafe5361e8bee8c5f8 100644
--- a/src/runtime/runtime-array.cc
+++ b/src/runtime/runtime-array.cc
@@ -391,6 +391,19 @@ RUNTIME_FUNCTION(Runtime_InternalArrayConstructor) {
Handle<AllocationSite>::null(), caller_args);
}
+RUNTIME_FUNCTION(Runtime_ArraySingleArgumentConstructor) {
+ HandleScope scope(isolate);
+ CONVERT_ARG_HANDLE_CHECKED(JSFunction, constructor, 0);
+ Object** argument_base = reinterpret_cast<Object**>(args[1]);
+ CONVERT_SMI_ARG_CHECKED(argument_count, 2);
+ CONVERT_ARG_HANDLE_CHECKED(Object, raw_site, 3);
+ Handle<AllocationSite> casted_site =
+ raw_site->IsUndefined() ? Handle<AllocationSite>::null()
+ : Handle<AllocationSite>::cast(raw_site);
+ Arguments constructor_args(argument_count, argument_base);
+ return ArrayConstructorCommon(isolate, constructor, constructor, casted_site,
+ &constructor_args);
+}
RUNTIME_FUNCTION(Runtime_NormalizeElements) {
HandleScope scope(isolate);
« no previous file with comments | « src/runtime/runtime.h ('k') | src/x64/code-stubs-x64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698