Commit 407b635c authored by Omer Katz's avatar Omer Katz Committed by Commit Bot

heap: MarkingVisitor should also flush write_barrier_worklist_

Bug: 986235
Change-Id: Idf6c50f07977804ae4a9d78a904043ab0bb7ba8e
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2007049Reviewed-by: default avatarMichael Lippautz <mlippautz@chromium.org>
Commit-Queue: Omer Katz <omerkatz@chromium.org>
Cr-Commit-Position: refs/heads/master@{#732791}
parent d6d10b7c
......@@ -280,8 +280,9 @@ void MarkingVisitor::ConservativelyMarkAddress(BasePage* page,
AccountMarkedBytes(header);
}
void MarkingVisitor::FlushMarkingWorklist() {
void MarkingVisitor::FlushMarkingWorklists() {
marking_worklist_.FlushToGlobal();
write_barrier_worklist_.FlushToGlobal();
}
ConcurrentMarkingVisitor::ConcurrentMarkingVisitor(ThreadState* state,
......
......@@ -191,7 +191,7 @@ class PLATFORM_EXPORT MarkingVisitor
// allowed to be in construction.
void VisitMarkedHeader(HeapObjectHeader* header);
void FlushMarkingWorklist();
void FlushMarkingWorklists();
private:
// Exact version of the marking write barriers.
......
......@@ -1171,7 +1171,7 @@ void ThreadState::IncrementalMarkingStart(BlinkGC::GCReason reason) {
// No active concurrent markers yet, so it is safe to write to
// concurrently_marked_bytes_ without a lock.
concurrently_marked_bytes_ = 0;
current_gc_data_.visitor->FlushMarkingWorklist();
current_gc_data_.visitor->FlushMarkingWorklists();
// Check that the marking worklist has enough private segments for all
// concurrent marking tasks.
const uint8_t max_concurrent_task_id =
......@@ -1238,7 +1238,7 @@ void ThreadState::IncrementalMarkingStep(BlinkGC::StackState stack_state,
}
bool ThreadState::ConcurrentMarkingStep() {
current_gc_data_.visitor->FlushMarkingWorklist();
current_gc_data_.visitor->FlushMarkingWorklists();
if (!Heap().GetMarkingWorklist()->IsGlobalPoolEmpty()) {
ScheduleConcurrentMarking();
return false;
......
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