Commit 25fbd950 authored by Dominik Inführ's avatar Dominik Inführ Committed by Commit Bot

[heap] Record slots in atomic pause

Bug: chromium:851877
Change-Id: Ib3b4ec7086ecf2115e42a30fab10be1ae6b67593
Reviewed-on: https://chromium-review.googlesource.com/1096943Reviewed-by: 's avatarUlan Degenbaev <ulan@chromium.org>
Commit-Queue: Dominik Inführ <dinfuehr@google.com>
Cr-Commit-Position: refs/heads/master@{#53663}
parent b8bb2530
......@@ -364,22 +364,10 @@ class ConcurrentMarkingVisitor final
for (int i = 0; i < table->Capacity(); i++) {
HeapObject* key = HeapObject::cast(table->KeyAt(i));
Object** key_slot =
table->RawFieldOfElementAt(EphemeronHashTable::EntryToIndex(i));
Object** value_slot =
table->RawFieldOfElementAt(EphemeronHashTable::EntryToValueIndex(i));
MarkCompactCollector::RecordSlot(table, key_slot, key);
if (marking_state_.IsBlackOrGrey(key)) {
Object** value_slot = table->RawFieldOfElementAt(
EphemeronHashTable::EntryToValueIndex(i));
VisitPointer(table, value_slot);
} else {
Object* value = *value_slot;
if (value->IsHeapObject()) {
MarkCompactCollector::RecordSlot(table, value_slot,
HeapObject::cast(value));
}
}
}
......
......@@ -1861,6 +1861,9 @@ void MarkCompactCollector::ProcessWeakCollections() {
for (int i = 0; i < table->Capacity(); i++) {
HeapObject* heap_object = HeapObject::cast(table->KeyAt(i));
if (non_atomic_marking_state()->IsBlackOrGrey(heap_object)) {
Object** key_slot =
table->RawFieldOfElementAt(EphemeronHashTable::EntryToIndex(i));
RecordSlot(table, key_slot, heap_object);
Object** value_slot = table->RawFieldOfElementAt(
EphemeronHashTable::EntryToValueIndex(i));
if (V8_UNLIKELY(FLAG_track_retaining_path) &&
......
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