Make VerifyMarking work in the presence of grey objects
authorjochen <jochen@chromium.org>
Mon, 9 Mar 2015 15:01:34 +0000 (08:01 -0700)
committerCommit bot <commit-bot@chromium.org>
Mon, 9 Mar 2015 15:01:42 +0000 (15:01 +0000)
R=hpayer@chromium.org
LOG=n
BUG=none

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

Cr-Commit-Position: refs/heads/master@{#27079}

src/heap/mark-compact.cc

index 8539596a62e5cfbd8f4c8850f929ade5e31f1d96..0c9eeff0041d3c92988d407e162bb50d81718468 100644 (file)
@@ -99,6 +99,7 @@ static void VerifyMarking(Heap* heap, Address bottom, Address top) {
   for (Address current = bottom; current < top; current += kPointerSize) {
     object = HeapObject::FromAddress(current);
     if (MarkCompactCollector::IsMarked(object)) {
+      CHECK(Marking::IsBlack(Marking::MarkBitFrom(object)));
       CHECK(current >= next_object_must_be_here_or_later);
       object->Iterate(&visitor);
       next_object_must_be_here_or_later = current + object->Size();