Commit c4321962 authored by ulan's avatar ulan Committed by Commit bot

Check mark bit of the found object in MarkCompactCollector::IsSlotInBlackObject.

BUG=

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

Cr-Commit-Position: refs/heads/master@{#27673}
parent d995d4bd
...@@ -3138,6 +3138,7 @@ bool MarkCompactCollector::IsSlotInBlackObject(Page* p, Address slot, ...@@ -3138,6 +3138,7 @@ bool MarkCompactCollector::IsSlotInBlackObject(Page* p, Address slot,
cell_base += (start_index - cell_base_start_index) * 32 * kPointerSize; cell_base += (start_index - cell_base_start_index) * 32 * kPointerSize;
Address address = cell_base + offset * kPointerSize; Address address = cell_base + offset * kPointerSize;
HeapObject* object = HeapObject::FromAddress(address); HeapObject* object = HeapObject::FromAddress(address);
CHECK(Marking::IsBlack(Marking::MarkBitFrom(object)));
CHECK(object->address() < reinterpret_cast<Address>(slot)); CHECK(object->address() < reinterpret_cast<Address>(slot));
if (object->address() <= slot && if (object->address() <= slot &&
(object->address() + object->Size()) > slot) { (object->address() + object->Size()) > slot) {
......
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