diff options
Diffstat (limited to 'deps/v8/src/mips/assembler-mips-inl.h')
-rw-r--r-- | deps/v8/src/mips/assembler-mips-inl.h | 60 |
1 files changed, 14 insertions, 46 deletions
diff --git a/deps/v8/src/mips/assembler-mips-inl.h b/deps/v8/src/mips/assembler-mips-inl.h index bb422a3fcd..f4bddf5461 100644 --- a/deps/v8/src/mips/assembler-mips-inl.h +++ b/deps/v8/src/mips/assembler-mips-inl.h @@ -40,7 +40,7 @@ #include "src/mips/assembler-mips.h" #include "src/assembler.h" -#include "src/debug.h" +#include "src/debug/debug.h" namespace v8 { @@ -117,7 +117,7 @@ int FPURegister::ToAllocationIndex(FPURegister reg) { // ----------------------------------------------------------------------------- // RelocInfo. -void RelocInfo::apply(intptr_t delta, ICacheFlushMode icache_flush_mode) { +void RelocInfo::apply(intptr_t delta) { if (IsCodeTarget(rmode_)) { uint32_t scope1 = (uint32_t) target_address() & ~kImm28Mask; uint32_t scope2 = reinterpret_cast<uint32_t>(pc_) & ~kImm28Mask; @@ -195,11 +195,6 @@ Address Assembler::target_address_from_return_address(Address pc) { } -Address Assembler::break_address_from_return_address(Address pc) { - return pc - Assembler::kPatchDebugBreakSlotReturnOffset; -} - - void Assembler::set_target_internal_reference_encoded_at(Address pc, Address target) { // Encoded internal references are lui/ori load of 32-bit abolute address. @@ -359,22 +354,18 @@ void RelocInfo::set_code_age_stub(Code* stub, } -Address RelocInfo::call_address() { - DCHECK((IsJSReturn(rmode()) && IsPatchedReturnSequence()) || - (IsDebugBreakSlot(rmode()) && IsPatchedDebugBreakSlotSequence())); - // The pc_ offset of 0 assumes mips patched return sequence per - // debug-mips.cc BreakLocation::SetDebugBreakAtReturn(), or - // debug break slot per BreakLocation::SetDebugBreakAtSlot(). +Address RelocInfo::debug_call_address() { + // The pc_ offset of 0 assumes patched debug break slot or return + // sequence. + DCHECK(IsDebugBreakSlot(rmode()) && IsPatchedDebugBreakSlotSequence()); return Assembler::target_address_at(pc_, host_); } -void RelocInfo::set_call_address(Address target) { - DCHECK((IsJSReturn(rmode()) && IsPatchedReturnSequence()) || - (IsDebugBreakSlot(rmode()) && IsPatchedDebugBreakSlotSequence())); - // The pc_ offset of 0 assumes mips patched return sequence per - // debug-mips.cc BreakLocation::SetDebugBreakAtReturn(), or - // debug break slot per BreakLocation::SetDebugBreakAtSlot(). +void RelocInfo::set_debug_call_address(Address target) { + DCHECK(IsDebugBreakSlot(rmode()) && IsPatchedDebugBreakSlotSequence()); + // The pc_ offset of 0 assumes patched debug break slot or return + // sequence. Assembler::set_target_address_at(pc_, host_, target); if (host() != NULL) { Object* target_code = Code::GetCodeFromTargetAddress(target); @@ -384,23 +375,6 @@ void RelocInfo::set_call_address(Address target) { } -Object* RelocInfo::call_object() { - return *call_object_address(); -} - - -Object** RelocInfo::call_object_address() { - DCHECK((IsJSReturn(rmode()) && IsPatchedReturnSequence()) || - (IsDebugBreakSlot(rmode()) && IsPatchedDebugBreakSlotSequence())); - return reinterpret_cast<Object**>(pc_ + 2 * Assembler::kInstrSize); -} - - -void RelocInfo::set_call_object(Object* target) { - *call_object_address() = target; -} - - void RelocInfo::WipeOut() { DCHECK(IsEmbeddedObject(rmode_) || IsCodeTarget(rmode_) || IsRuntimeEntry(rmode_) || IsExternalReference(rmode_) || @@ -449,11 +423,8 @@ void RelocInfo::Visit(Isolate* isolate, ObjectVisitor* visitor) { visitor->VisitInternalReference(this); } else if (RelocInfo::IsCodeAgeSequence(mode)) { visitor->VisitCodeAgeSequence(this); - } else if (((RelocInfo::IsJSReturn(mode) && - IsPatchedReturnSequence()) || - (RelocInfo::IsDebugBreakSlot(mode) && - IsPatchedDebugBreakSlotSequence())) && - isolate->debug()->has_break_points()) { + } else if (RelocInfo::IsDebugBreakSlot(mode) && + IsPatchedDebugBreakSlotSequence()) { visitor->VisitDebugTarget(this); } else if (RelocInfo::IsRuntimeEntry(mode)) { visitor->VisitRuntimeEntry(this); @@ -477,11 +448,8 @@ void RelocInfo::Visit(Heap* heap) { StaticVisitor::VisitInternalReference(this); } else if (RelocInfo::IsCodeAgeSequence(mode)) { StaticVisitor::VisitCodeAgeSequence(heap, this); - } else if (heap->isolate()->debug()->has_break_points() && - ((RelocInfo::IsJSReturn(mode) && - IsPatchedReturnSequence()) || - (RelocInfo::IsDebugBreakSlot(mode) && - IsPatchedDebugBreakSlotSequence()))) { + } else if (RelocInfo::IsDebugBreakSlot(mode) && + IsPatchedDebugBreakSlotSequence()) { StaticVisitor::VisitDebugTarget(heap, this); } else if (RelocInfo::IsRuntimeEntry(mode)) { StaticVisitor::VisitRuntimeEntry(this); |