Index: src/incremental-marking.cc |
diff --git a/src/incremental-marking.cc b/src/incremental-marking.cc |
index 60a21eed6a984efe65db86c08f890060a3e25119..88ebd783ea8369a0839e9c1e39207596aafa8972 100644 |
--- a/src/incremental-marking.cc |
+++ b/src/incremental-marking.cc |
@@ -117,14 +117,12 @@ class IncrementalMarkingMarkingVisitor : public ObjectVisitor { |
incremental_marking_(incremental_marking) { |
} |
- void VisitEmbeddedPointer(Code* host, Object** p) { |
- Object* obj = *p; |
- if (obj->NonFailureIsHeapObject()) { |
- heap_->mark_compact_collector()->RecordSlot( |
- reinterpret_cast<Object**>(host), |
- p, |
- obj); |
- MarkObject(obj); |
+ void VisitEmbeddedPointer(RelocInfo* rinfo) { |
+ ASSERT(rinfo->rmode() == RelocInfo::EMBEDDED_OBJECT); |
+ Object* target = rinfo->target_object(); |
+ if (target->NonFailureIsHeapObject()) { |
+ heap_->mark_compact_collector()->RecordRelocSlot(rinfo, target); |
+ MarkObject(target); |
} |
} |