[heap] Enter final pause for embedder tracer in MarkLiveObjects
MarkCompactCollector::Prepare is too early in the rare case that we don't have a marking deque yet. EnterFinalPause could then trigger Heap::RegisterExternallyReferencedObject which rightfully fails because MC is not properly set up. Note that the DCHECK also triggers, without actual consequences, for aborting incremental marking. BUG=468240 TBR=jochen@chromium.org Review-Url: https://codereview.chromium.org/2611753002 Cr-Commit-Position: refs/heads/master@{#42044}
This commit is contained in:
parent
a0eb5ab5fc
commit
d75023f3a1
@ -806,8 +806,6 @@ void MarkCompactCollector::Prepare() {
|
||||
heap_->local_embedder_heap_tracer()->TracePrologue();
|
||||
}
|
||||
|
||||
heap_->local_embedder_heap_tracer()->EnterFinalPause();
|
||||
|
||||
// Don't start compaction if we are in the middle of incremental
|
||||
// marking cycle. We did not collect any slots.
|
||||
if (!FLAG_never_compact && !was_marked_incrementally_) {
|
||||
@ -2440,6 +2438,8 @@ void MarkCompactCollector::MarkLiveObjects() {
|
||||
|
||||
marking_deque()->StartUsing();
|
||||
|
||||
heap_->local_embedder_heap_tracer()->EnterFinalPause();
|
||||
|
||||
{
|
||||
TRACE_GC(heap()->tracer(), GCTracer::Scope::MC_MARK_PREPARE_CODE_FLUSH);
|
||||
PrepareForCodeFlushing();
|
||||
|
Loading…
Reference in New Issue
Block a user