Index: src/ic/ic.cc |
diff --git a/src/ic/ic.cc b/src/ic/ic.cc |
index cfc2a81feee0f1d6119e3da25f3551bbe659321a..9523159c47a28dd33ffe04a755ebf0896cf84757 100644 |
--- a/src/ic/ic.cc |
+++ b/src/ic/ic.cc |
@@ -665,8 +665,6 @@ void IC::ConfigureVectorState(IC::State new_state) { |
nexus->ConfigureGeneric(); |
} else if (new_state == PREMONOMORPHIC) { |
nexus->ConfigurePremonomorphic(); |
- } else if (new_state == MEGAMORPHIC) { |
- nexus->ConfigureMegamorphic(); |
} else { |
UNREACHABLE(); |
} |
@@ -971,7 +969,8 @@ void IC::PatchCache(Handle<Name> name, Handle<Code> code) { |
CopyICToMegamorphicCache(name); |
} |
if (UseVector()) { |
- ConfigureVectorState(MEGAMORPHIC); |
+ ConfigureVectorState(kind() == Code::KEYED_LOAD_IC ? GENERIC |
+ : MEGAMORPHIC); |
} else { |
set_target(*megamorphic_stub()); |
} |