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

Unified Diff: src/type-info.cc

Issue 6894003: Better support for 'polymorphic' JS and external arrays (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: new strategy Created 9 years, 8 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
« src/ic.cc ('K') | « src/stub-cache.cc ('k') | src/v8-counters.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/type-info.cc
diff --git a/src/type-info.cc b/src/type-info.cc
index 1940601c4782dd157d8cb773c3de71aae7034fb2..d69026c7529d99db596f249f61d570c4249b5274 100644
--- a/src/type-info.cc
+++ b/src/type-info.cc
@@ -82,8 +82,8 @@ bool TypeFeedbackOracle::LoadIsMonomorphic(Property* expr) {
if (map_or_code->IsMap()) return true;
if (map_or_code->IsCode()) {
Handle<Code> code(Code::cast(*map_or_code));
- return code->kind() == Code::KEYED_EXTERNAL_ARRAY_LOAD_IC &&
- code->FindFirstMap() != NULL;
+ return code->is_keyed_load_stub() &&
+ code->ic_state() == MONOMORPHIC;
}
return false;
}
@@ -94,8 +94,8 @@ bool TypeFeedbackOracle::StoreIsMonomorphic(Expression* expr) {
if (map_or_code->IsMap()) return true;
if (map_or_code->IsCode()) {
Handle<Code> code(Code::cast(*map_or_code));
- return code->kind() == Code::KEYED_EXTERNAL_ARRAY_STORE_IC &&
- code->FindFirstMap() != NULL;
+ return code->is_keyed_store_stub() &&
+ code->ic_state() == MONOMORPHIC;
}
return false;
}
@@ -388,8 +388,8 @@ void TypeFeedbackOracle::PopulateMap(Handle<Code> code) {
SetInfo(position, target);
}
} else if (state == MONOMORPHIC) {
- if (kind == Code::KEYED_EXTERNAL_ARRAY_LOAD_IC ||
- kind == Code::KEYED_EXTERNAL_ARRAY_STORE_IC) {
+ if (kind == Code::KEYED_LOAD_IC ||
+ kind == Code::KEYED_STORE_IC) {
SetInfo(position, target);
} else if (target->kind() != Code::CALL_IC ||
target->check_type() == RECEIVER_MAP_CHECK) {
« src/ic.cc ('K') | « src/stub-cache.cc ('k') | src/v8-counters.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698