Commit 2b9de386 authored by jarin@chromium.org's avatar jarin@chromium.org

Fix incremental marking of native context when bootstrapping.

This should fix one of the arm64 build breaks - we have tried to mark
half-initialized native context there, but the normalized_map_cache
entry was still undefined.

R=hpayer@chromium.org
BUG=

Review URL: https://codereview.chromium.org/284633002

git-svn-id: https://v8.googlecode.com/svn/branches/bleeding_edge@21283 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
parent c0887a96
......@@ -222,9 +222,13 @@ class IncrementalMarkingMarkingVisitor
static void VisitNativeContextIncremental(Map* map, HeapObject* object) {
Context* context = Context::cast(object);
// We will mark cache black with a separate pass
// when we finish marking.
MarkObjectGreyDoNotEnqueue(context->normalized_map_cache());
// We will mark cache black with a separate pass when we finish marking.
// Note that GC can happen when the context is not fully initialized,
// so the cache can be undefined.
Object* cache = context->get(Context::NORMALIZED_MAP_CACHE_INDEX);
if (!cache->IsUndefined()) {
MarkObjectGreyDoNotEnqueue(cache);
}
VisitNativeContext(map, context);
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment