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

Unified Diff: src/factory.cc

Issue 437083004: Keep function.prototype fast. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Add TODO and make .prototype fast on creating the initial map Created 6 years, 4 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/objects.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/factory.cc
diff --git a/src/factory.cc b/src/factory.cc
index 60dc0b7a8d7a67fe2b507e10e23e89f15e24e881..864672143a800e0e6b5a4672f6697786f35a5341 100644
--- a/src/factory.cc
+++ b/src/factory.cc
@@ -1318,7 +1318,7 @@ Handle<JSObject> Factory::NewFunctionPrototype(Handle<JSFunction> function) {
// maps between prototypes of different constructors.
Handle<JSFunction> object_function(native_context->object_function());
ASSERT(object_function->has_initial_map());
- new_map = Map::Copy(handle(object_function->initial_map()));
+ new_map = Map::CopyAsPrototypeMap(handle(object_function->initial_map()));
}
Handle<JSObject> prototype = NewJSObjectFromMap(new_map);
« no previous file with comments | « no previous file | src/objects.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698