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

Unified Diff: src/bootstrapper.cc

Issue 2170743003: [api] Introduce fast instantiations cache (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: fixing uint issue under windows Created 4 years, 5 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/api-natives.cc ('k') | src/contexts.h » ('j') | src/objects.h » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/bootstrapper.cc
diff --git a/src/bootstrapper.cc b/src/bootstrapper.cc
index 181c20052734e217138906ee13d72c53a2e8c613..c32685649d6127715b32defaf3f172d3c4e72b71 100644
--- a/src/bootstrapper.cc
+++ b/src/bootstrapper.cc
@@ -2990,11 +2990,15 @@ bool Genesis::InstallNatives(GlobalContextType context_type) {
}
if (!CallUtilsFunction(isolate(), "PostNatives")) return false;
+ auto fast_template_instantiations_cache = isolate()->factory()->NewFixedArray(
+ TemplateInfo::kFastTemplateInstantiationsCacheSize);
+ native_context()->set_fast_template_instantiations_cache(
+ *fast_template_instantiations_cache);
- auto template_instantiations_cache = UnseededNumberDictionary::New(
+ auto slow_template_instantiations_cache = UnseededNumberDictionary::New(
isolate(), ApiNatives::kInitialFunctionCacheSize);
- native_context()->set_template_instantiations_cache(
- *template_instantiations_cache);
+ native_context()->set_slow_template_instantiations_cache(
+ *slow_template_instantiations_cache);
// Store the map for the %ObjectPrototype% after the natives has been compiled
// and the Object function has been set up.
« no previous file with comments | « src/api-natives.cc ('k') | src/contexts.h » ('j') | src/objects.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698