Index: src/arm/assembler-arm-inl.h |
diff --git a/src/arm/assembler-arm-inl.h b/src/arm/assembler-arm-inl.h |
index 2bd78ab801e474b0318dcdffdab99c1c3abdaccb..acd61feff89711daf952ae3714efc7c88a030545 100644 |
--- a/src/arm/assembler-arm-inl.h |
+++ b/src/arm/assembler-arm-inl.h |
@@ -165,6 +165,24 @@ void RelocInfo::set_target_cell(JSGlobalPropertyCell* cell, |
} |
+static const int kNoCodeAgeSequenceLength = 3; |
+ |
+Code* RelocInfo::code_age_stub() { |
+ ASSERT(rmode_ == RelocInfo::CODE_AGE_SEQUENCE); |
+ return Code::GetCodeFromTargetAddress( |
+ Memory::Address_at(pc_ + Assembler::kInstrSize * |
+ (kNoCodeAgeSequenceLength - 1))); |
+} |
+ |
+ |
+void RelocInfo::set_code_age_stub(Code* stub) { |
+ ASSERT(rmode_ == RelocInfo::CODE_AGE_SEQUENCE); |
+ Memory::Address_at(pc_ + Assembler::kInstrSize * |
+ (kNoCodeAgeSequenceLength - 1)) = |
+ stub->instruction_start(); |
+} |
+ |
+ |
Address RelocInfo::call_address() { |
// The 2 instructions offset assumes patched debug break slot or return |
// sequence. |
@@ -238,6 +256,8 @@ void RelocInfo::Visit(ObjectVisitor* visitor) { |
visitor->VisitGlobalPropertyCell(this); |
} else if (mode == RelocInfo::EXTERNAL_REFERENCE) { |
visitor->VisitExternalReference(this); |
+ } else if (RelocInfo::IsCodeAgeSequence(mode)) { |
+ visitor->VisitCodeAgeSequence(this); |
#ifdef ENABLE_DEBUGGER_SUPPORT |
// TODO(isolates): Get a cached isolate below. |
} else if (((RelocInfo::IsJSReturn(mode) && |
@@ -264,6 +284,8 @@ void RelocInfo::Visit(Heap* heap) { |
StaticVisitor::VisitGlobalPropertyCell(heap, this); |
} else if (mode == RelocInfo::EXTERNAL_REFERENCE) { |
StaticVisitor::VisitExternalReference(this); |
+ } else if (RelocInfo::IsCodeAgeSequence(mode)) { |
+ StaticVisitor::VisitCodeAgeSequence(heap, this); |
#ifdef ENABLE_DEBUGGER_SUPPORT |
} else if (heap->isolate()->debug()->has_break_points() && |
((RelocInfo::IsJSReturn(mode) && |