Reviewers: ulan,

Description:
Read object pointer atomically while updating slots

BUG=425003
[email protected]
LOG=n

Please review this at https://codereview.chromium.org/663023002/

Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge

Affected files (+2, -1 lines):
  M src/heap/mark-compact.cc


Index: src/heap/mark-compact.cc
diff --git a/src/heap/mark-compact.cc b/src/heap/mark-compact.cc
index f53fb6c177c675e4e74c685f9633d011398220f6..088e894d3b3272466c5fa8f753ee6c728a656e2a 100644
--- a/src/heap/mark-compact.cc
+++ b/src/heap/mark-compact.cc
@@ -2924,7 +2924,8 @@ class PointersUpdatingVisitor : public ObjectVisitor {
   }

   static inline void UpdateSlot(Heap* heap, Object** slot) {
-    Object* obj = *slot;
+    Object* obj = reinterpret_cast<Object*>(
+        base::NoBarrier_Load(reinterpret_cast<base::AtomicWord*>(slot)));

     if (!obj->IsHeapObject()) return;



--
--
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/d/optout.

Reply via email to