| Index: src/objects-visiting-inl.h
|
| diff --git a/src/objects-visiting-inl.h b/src/objects-visiting-inl.h
|
| index 4f1498844dc496c4aed94996b0d509cccba1602e..ce7cfcb8f78f5fe0d894f31ddc923c250f39e1ab 100644
|
| --- a/src/objects-visiting-inl.h
|
| +++ b/src/objects-visiting-inl.h
|
| @@ -309,9 +309,16 @@ void StaticMarkingVisitor<StaticVisitor>::VisitCodeTarget(
|
| // Monomorphic ICs are preserved when possible, but need to be flushed
|
| // when they might be keeping a Context alive, or when the heap is about
|
| // to be serialized.
|
| +
|
| + // TODO(mvstanton): CALL_IC in monomorphic state needs to be cleared because
|
| + // it's state is synced with a type feedback slot, which is always cleared on
|
| + // gc. If we leave it alone, we'll end up in a hybrid of (cleared feedback
|
| + // slot but monomorphic IC), which is complex.
|
| if (FLAG_cleanup_code_caches_at_gc && target->is_inline_cache_stub()
|
| && (target->ic_state() == MEGAMORPHIC || target->ic_state() == GENERIC ||
|
| target->ic_state() == POLYMORPHIC || heap->flush_monomorphic_ics() ||
|
| + (target->ic_state() == MONOMORPHIC &&
|
| + target->kind() == Code::CALL_IC) ||
|
| Serializer::enabled() || target->ic_age() != heap->global_ic_age())) {
|
| IC::Clear(target->GetIsolate(), rinfo->pc(),
|
| rinfo->host()->constant_pool());
|
|
|