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

Unified Diff: src/ic.cc

Issue 8241003: Elements kind conversion in generated code (ia32). (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Applied suggested changes. Created 9 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/ia32/code-stubs-ia32.cc ('k') | test/mjsunit/element-kind.js » ('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 d5056a9ce8ce3a12c5160ade1fe317383835c3b3..09e9f0f9a9e7d6433e71fe45a01281780e25f5b4 100644
--- a/src/ic.cc
+++ b/src/ic.cc
@@ -1593,7 +1593,7 @@ void KeyedIC::GetReceiverMapsForStub(Code* stub, MapList* result) {
RelocInfo* info = it.rinfo();
Object* object = info->target_object();
ASSERT(object->IsMap());
- result->Add(Map::cast(object));
+ AddOneReceiverMapIfMissing(result, Map::cast(object));
}
}
}
@@ -1781,12 +1781,6 @@ Map* GetTransitionedMap(Map* map, MapList* maps_list) {
MaybeObject* KeyedStoreIC::ComputePolymorphicStub(
MapList* receiver_maps,
StrictModeFlag strict_mode) {
- // TODO(yangguo): <remove>
- Code* generic_stub = (strict_mode == kStrictMode)
- ? isolate()->builtins()->builtin(Builtins::kKeyedStoreIC_Generic_Strict)
- : isolate()->builtins()->builtin(Builtins::kKeyedStoreIC_Generic);
- // </remove>
-
// Collect MONOMORPHIC stubs for all target_receiver_maps.
CodeList handler_ics(receiver_maps->length());
MapList transitioned_maps(receiver_maps->length());
@@ -1795,15 +1789,11 @@ MaybeObject* KeyedStoreIC::ComputePolymorphicStub(
MaybeObject* maybe_cached_stub = NULL;
Map* transitioned_map = GetTransitionedMap(receiver_map, receiver_maps);
if (transitioned_map != NULL) {
- // TODO(yangguo): Enable this code!
- // maybe_cached_stub = FastElementsConversionStub(
- // receiver_map->elements_kind(), // original elements_kind
- // transitioned_map->elements_kind(),
- // receiver_map->instance_type() == JS_ARRAY_TYPE, // is_js_array
- // strict_mode_).TryGetCode();
- // TODO(yangguo): <remove>
- maybe_cached_stub = generic_stub;
- // </remove>
+ maybe_cached_stub = FastElementsConversionStub(
+ receiver_map->elements_kind(), // original elements_kind
+ transitioned_map->elements_kind(),
+ receiver_map->instance_type() == JS_ARRAY_TYPE, // is_js_array
+ strict_mode).TryGetCode();
} else {
maybe_cached_stub = ComputeMonomorphicStubWithoutMapCheck(
receiver_map, strict_mode);
« no previous file with comments | « src/ia32/code-stubs-ia32.cc ('k') | test/mjsunit/element-kind.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698