Revision: 7456
Author:   [email protected]
Date:     Thu Mar 31 04:52:51 2011
Log:      Untank build after last commit.
Review URL: http://codereview.chromium.org/6728021
http://code.google.com/p/v8/source/detail?r=7456

Modified:
 /branches/bleeding_edge/src/objects-inl.h

=======================================
--- /branches/bleeding_edge/src/objects-inl.h   Thu Mar 31 03:55:53 2011
+++ /branches/bleeding_edge/src/objects-inl.h   Thu Mar 31 04:52:51 2011
@@ -1158,9 +1158,12 @@


 Heap* HeapObject::GetHeap() {
-  uintptr_t addr = reinterpret_cast<uintptr_t>(this);
-  addr >>= kHeapDescriptorGranularityBits;
-  return heap_descriptors[addr].heap;
+  // During GC, the map pointer in HeapObject is used in various ways that
+  // prevent us from retrieving Heap from the map.
+ // Assert that we are not in GC, implement GC code in a way that it doesn't
+  // pull heap from the map.
+  ASSERT(HEAP->is_safe_to_read_maps());
+  return map()->heap();
 }


--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev

Reply via email to