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

Unified Diff: src/ic/ic.cc

Issue 2428473002: [ic] Cache weak cells containing prototypes in respective PrototypeInfo objects. (Closed)
Patch Set: Created 4 years, 2 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/ic/ia32/handler-compiler-ia32.cc ('k') | src/ic/mips/handler-compiler-mips.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/ic/ic.cc
diff --git a/src/ic/ic.cc b/src/ic/ic.cc
index d036b343d83c90b602686287c463bc4b6855b2e0..5a04ea25b07e24e26c0032e3027670a82275708a 100644
--- a/src/ic/ic.cc
+++ b/src/ic/ic.cc
@@ -893,10 +893,10 @@ Handle<Object> LoadIC::SimpleLoadFromPrototype(Handle<Map> receiver_map,
Map::GetOrCreatePrototypeChainValidityCell(receiver_map, isolate());
DCHECK(!validity_cell.is_null());
- Factory* factory = isolate()->factory();
-
- Handle<WeakCell> holder_cell = factory->NewWeakCell(holder);
- return factory->NewTuple3(validity_cell, holder_cell, smi_handler);
+ Handle<WeakCell> holder_cell =
+ Map::GetOrCreatePrototypeWeakCell(holder, isolate());
+ return isolate()->factory()->NewTuple3(validity_cell, holder_cell,
+ smi_handler);
}
bool IsCompatibleReceiver(LookupIterator* lookup, Handle<Map> receiver_map) {
« no previous file with comments | « src/ic/ia32/handler-compiler-ia32.cc ('k') | src/ic/mips/handler-compiler-mips.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698