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

Side by Side Diff: src/api-natives.h

Issue 988283003: use a hash table for the function cache as blink is leaking functiontemplates (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 9 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
« no previous file with comments | « no previous file | src/api-natives.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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_API_NATIVES_H_ 5 #ifndef V8_API_NATIVES_H_
6 #define V8_API_NATIVES_H_ 6 #define V8_API_NATIVES_H_
7 7
8 #include "src/handles.h" 8 #include "src/handles.h"
9 9
10 namespace v8 { 10 namespace v8 {
11 namespace internal { 11 namespace internal {
12 12
13 class ApiNatives { 13 class ApiNatives {
14 public: 14 public:
15 static const int kInitialFunctionCacheSize = 256;
16
15 MUST_USE_RESULT static MaybeHandle<JSFunction> InstantiateFunction( 17 MUST_USE_RESULT static MaybeHandle<JSFunction> InstantiateFunction(
16 Handle<FunctionTemplateInfo> data); 18 Handle<FunctionTemplateInfo> data);
17 19
18 MUST_USE_RESULT static MaybeHandle<JSObject> InstantiateObject( 20 MUST_USE_RESULT static MaybeHandle<JSObject> InstantiateObject(
19 Handle<ObjectTemplateInfo> data); 21 Handle<ObjectTemplateInfo> data);
20 22
21 MUST_USE_RESULT static MaybeHandle<FunctionTemplateInfo> ConfigureInstance( 23 MUST_USE_RESULT static MaybeHandle<FunctionTemplateInfo> ConfigureInstance(
22 Isolate* isolate, Handle<FunctionTemplateInfo> instance, 24 Isolate* isolate, Handle<FunctionTemplateInfo> instance,
23 Handle<JSObject> data); 25 Handle<JSObject> data);
24 26
(...skipping 19 matching lines...) Expand all
44 PropertyAttributes attributes); 46 PropertyAttributes attributes);
45 47
46 static void AddNativeDataProperty(Isolate* isolate, Handle<TemplateInfo> info, 48 static void AddNativeDataProperty(Isolate* isolate, Handle<TemplateInfo> info,
47 Handle<AccessorInfo> property); 49 Handle<AccessorInfo> property);
48 }; 50 };
49 51
50 } // namespace internal 52 } // namespace internal
51 } // namespace v8 53 } // namespace v8
52 54
53 #endif 55 #endif
OLDNEW
« no previous file with comments | « no previous file | src/api-natives.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698