Revision: 15849
Author: [email protected]
Date: Wed Jul 24 02:19:55 2013
Log: Added check to debug object migration crashes.
BUG=
[email protected]
Review URL: https://codereview.chromium.org/20055002
http://code.google.com/p/v8/source/detail?r=15849
Modified:
/branches/bleeding_edge/src/mark-compact.cc
=======================================
--- /branches/bleeding_edge/src/mark-compact.cc Wed Jul 24 01:50:03 2013
+++ /branches/bleeding_edge/src/mark-compact.cc Wed Jul 24 02:19:55 2013
@@ -2724,7 +2724,21 @@
HEAP_PROFILE(heap(), ObjectMoveEvent(src, dst));
// TODO(hpayer): Replace that check with an assert.
CHECK(dest != LO_SPACE && size <= Page::kMaxNonCodeHeapObjectSize);
+ // Objects in old pointer space and old data space can just be moved by
+ // compaction to a different page in the same space.
+ // TODO(hpayer): Replace that following checks with asserts.
+ CHECK(!heap_->old_pointer_space()->Contains(src) ||
+ (heap_->old_pointer_space()->Contains(dst) &&
+ heap_->TargetSpace(HeapObject::FromAddress(src)) ==
+ heap_->old_pointer_space()));
+ CHECK(!heap_->old_data_space()->Contains(src) ||
+ (heap_->old_data_space()->Contains(dst) &&
+ heap_->TargetSpace(HeapObject::FromAddress(src)) ==
+ heap_->old_data_space()));
if (dest == OLD_POINTER_SPACE) {
+ // TODO(hpayer): Replace this check with an assert.
+ CHECK(heap_->TargetSpace(HeapObject::FromAddress(src)) ==
+ heap_->old_pointer_space());
Address src_slot = src;
Address dst_slot = dst;
ASSERT(IsAligned(size, kPointerSize));
--
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev
---
You received this message because you are subscribed to the Google Groups "v8-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.