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

Unified Diff: src/ic.cc

Issue 228263005: Implement structural function and array types (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Fixing Windows compilation Created 6 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
« no previous file with comments | « src/ia32/stub-cache-ia32.cc ('k') | src/objects-debug.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/ic.cc
diff --git a/src/ic.cc b/src/ic.cc
index ecf0e9a8d68eca7fb8e611118f2aefc7f58eeeed..86bef05e221120a5de4bc06d9c0dffd2990de96e 100644
--- a/src/ic.cc
+++ b/src/ic.cc
@@ -680,7 +680,8 @@ bool IC::UpdatePolymorphicIC(Handle<HeapType> type,
for (int i = 0; i < number_of_types; i++) {
Handle<HeapType> current_type = types.at(i);
- if (current_type->IsClass() && current_type->AsClass()->is_deprecated()) {
+ if (current_type->IsClass() &&
+ current_type->AsClass()->Map()->is_deprecated()) {
// Filter out deprecated maps to ensure their instances get migrated.
++deprecated_types;
} else if (type->NowIs(current_type)) {
@@ -691,8 +692,8 @@ bool IC::UpdatePolymorphicIC(Handle<HeapType> type,
} else if (handler_to_overwrite == -1 &&
current_type->IsClass() &&
type->IsClass() &&
- IsTransitionOfMonomorphicTarget(*current_type->AsClass(),
- *type->AsClass())) {
+ IsTransitionOfMonomorphicTarget(*current_type->AsClass()->Map(),
+ *type->AsClass()->Map())) {
handler_to_overwrite = i;
}
}
@@ -734,10 +735,11 @@ Handle<Map> IC::TypeToMap(HeapType* type, Isolate* isolate) {
return isolate->factory()->heap_number_map();
if (type->Is(HeapType::Boolean())) return isolate->factory()->boolean_map();
if (type->IsConstant()) {
- return handle(Handle<JSGlobalObject>::cast(type->AsConstant())->map());
+ return handle(
+ Handle<JSGlobalObject>::cast(type->AsConstant()->Value())->map());
}
ASSERT(type->IsClass());
- return type->AsClass();
+ return type->AsClass()->Map();
}
« no previous file with comments | « src/ia32/stub-cache-ia32.cc ('k') | src/objects-debug.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698