Index: src/arm64/assembler-arm64-inl.h |
diff --git a/src/arm64/assembler-arm64-inl.h b/src/arm64/assembler-arm64-inl.h |
index bbd44c5f106bec92a28db8075c26ecdb1ebcf500..ff5c8af0fdd815f5e5221e86b665cd081a6f4c45 100644 |
--- a/src/arm64/assembler-arm64-inl.h |
+++ b/src/arm64/assembler-arm64-inl.h |
@@ -17,7 +17,7 @@ namespace internal { |
bool CpuFeatures::SupportsCrankshaft() { return true; } |
-void RelocInfo::apply(intptr_t delta, ICacheFlushMode icache_flush_mode) { |
+void RelocInfo::apply(intptr_t delta) { |
// On arm64 only internal references need extra work. |
DCHECK(RelocInfo::IsInternalReference(rmode_)); |
@@ -611,11 +611,6 @@ Address Assembler::target_address_from_return_address(Address pc) { |
} |
-Address Assembler::break_address_from_return_address(Address pc) { |
- return pc - Assembler::kPatchDebugBreakSlotReturnOffset; |
-} |
- |
- |
Address Assembler::return_address_from_call_start(Address pc) { |
// The call, generated by MacroAssembler::Call, is one of two possible |
// sequences: |
@@ -825,18 +820,18 @@ void RelocInfo::set_code_age_stub(Code* stub, |
} |
-Address RelocInfo::call_address() { |
- DCHECK((IsJSReturn(rmode()) && IsPatchedReturnSequence()) || |
- (IsDebugBreakSlot(rmode()) && IsPatchedDebugBreakSlotSequence())); |
+Address RelocInfo::debug_call_address() { |
+ DCHECK(IsDebugBreakSlot(rmode()) && IsPatchedDebugBreakSlotSequence()); |
// For the above sequences the Relocinfo points to the load literal loading |
// the call address. |
+ STATIC_ASSERT(Assembler::kPatchDebugBreakSlotAddressOffset == 0); |
return Assembler::target_address_at(pc_, host_); |
} |
-void RelocInfo::set_call_address(Address target) { |
- DCHECK((IsJSReturn(rmode()) && IsPatchedReturnSequence()) || |
- (IsDebugBreakSlot(rmode()) && IsPatchedDebugBreakSlotSequence())); |
+void RelocInfo::set_debug_call_address(Address target) { |
+ DCHECK(IsDebugBreakSlot(rmode()) && IsPatchedDebugBreakSlotSequence()); |
+ STATIC_ASSERT(Assembler::kPatchDebugBreakSlotAddressOffset == 0); |
Assembler::set_target_address_at(pc_, host_, target); |
if (host() != NULL) { |
Object* target_code = Code::GetCodeFromTargetAddress(target); |
@@ -862,7 +857,7 @@ bool RelocInfo::IsPatchedReturnSequence() { |
// The sequence must be: |
// ldr ip0, [pc, #offset] |
// blr ip0 |
- // See arm64/debug-arm64.cc BreakLocation::SetDebugBreakAtReturn(). |
+ // See arm64/debug-arm64.cc DebugCodegen::PatchDebugBreakSlot |
Instruction* i1 = reinterpret_cast<Instruction*>(pc_); |
Instruction* i2 = i1->following(); |
return i1->IsLdrLiteralX() && (i1->Rt() == kIp0Code) && |
@@ -888,10 +883,8 @@ void RelocInfo::Visit(Isolate* isolate, ObjectVisitor* visitor) { |
visitor->VisitExternalReference(this); |
} else if (mode == RelocInfo::INTERNAL_REFERENCE) { |
visitor->VisitInternalReference(this); |
- } else if (((RelocInfo::IsJSReturn(mode) && |
- IsPatchedReturnSequence()) || |
- (RelocInfo::IsDebugBreakSlot(mode) && |
- IsPatchedDebugBreakSlotSequence())) && |
+ } else if (RelocInfo::IsDebugBreakSlot(mode) && |
+ IsPatchedDebugBreakSlotSequence() && |
isolate->debug()->has_break_points()) { |
visitor->VisitDebugTarget(this); |
} else if (RelocInfo::IsRuntimeEntry(mode)) { |
@@ -914,10 +907,8 @@ void RelocInfo::Visit(Heap* heap) { |
} else if (mode == RelocInfo::INTERNAL_REFERENCE) { |
StaticVisitor::VisitInternalReference(this); |
} else if (heap->isolate()->debug()->has_break_points() && |
- ((RelocInfo::IsJSReturn(mode) && |
- IsPatchedReturnSequence()) || |
- (RelocInfo::IsDebugBreakSlot(mode) && |
- IsPatchedDebugBreakSlotSequence()))) { |
+ RelocInfo::IsDebugBreakSlot(mode) && |
+ IsPatchedDebugBreakSlotSequence()) { |
StaticVisitor::VisitDebugTarget(heap, this); |
} else if (RelocInfo::IsRuntimeEntry(mode)) { |
StaticVisitor::VisitRuntimeEntry(this); |