Index: src/ic/stub-cache.cc |
diff --git a/src/ic/stub-cache.cc b/src/ic/stub-cache.cc |
index 5d71c1fe6b2a5d422402d929c93746c38d98151d..c36603e52d2105119f5e0f775934f665a003dc49 100644 |
--- a/src/ic/stub-cache.cc |
+++ b/src/ic/stub-cache.cc |
@@ -75,12 +75,14 @@ Code* StubCache::Get(Name* name, Map* map, Code::Flags flags) { |
flags = CommonStubCacheChecks(name, map, flags); |
int primary_offset = PrimaryOffset(name, flags, map); |
Entry* primary = entry(primary_, primary_offset); |
- if (primary->key == name && primary->map == map) { |
+ if (primary->key == name && primary->map == map && |
+ flags == Code::RemoveHolderFromFlags(primary->value->flags())) { |
return primary->value; |
} |
int secondary_offset = SecondaryOffset(name, flags, primary_offset); |
Entry* secondary = entry(secondary_, secondary_offset); |
- if (secondary->key == name && secondary->map == map) { |
+ if (secondary->key == name && secondary->map == map && |
+ flags == Code::RemoveHolderFromFlags(secondary->value->flags())) { |
return secondary->value; |
} |
return NULL; |