| Index: src/mark-compact.cc
|
| diff --git a/src/mark-compact.cc b/src/mark-compact.cc
|
| index df4739ea04d9b1b271705ae2922ac14ecc6388fb..31fa7afddde4c29b5dd5a884c3541bfa8dcbef08 100644
|
| --- a/src/mark-compact.cc
|
| +++ b/src/mark-compact.cc
|
| @@ -4080,6 +4080,20 @@ void MarkCompactCollector::RecordCodeEntrySlot(Address slot, Code* target) {
|
| }
|
|
|
|
|
| +void MarkCompactCollector::RecordCodeTargetPatch(Address pc, Code* target) {
|
| + ASSERT(heap()->gc_state() == Heap::MARK_COMPACT);
|
| + if (is_compacting()) {
|
| + Code* host = heap()->isolate()->inner_pointer_to_code_cache()->
|
| + GcSafeFindCodeForInnerPointer(pc);
|
| + MarkBit mark_bit = Marking::MarkBitFrom(host);
|
| + if (Marking::IsBlack(mark_bit)) {
|
| + RelocInfo rinfo(pc, RelocInfo::CODE_TARGET, 0, host);
|
| + RecordRelocSlot(&rinfo, target);
|
| + }
|
| + }
|
| +}
|
| +
|
| +
|
| static inline SlotsBuffer::SlotType DecodeSlotType(
|
| SlotsBuffer::ObjectSlot slot) {
|
| return static_cast<SlotsBuffer::SlotType>(reinterpret_cast<intptr_t>(slot));
|
|
|