| OLD | NEW |
| 1 // Copyright 2013 the V8 project authors. All rights reserved. | 1 // Copyright 2013 the V8 project authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #if V8_TARGET_ARCH_ARM64 | 5 #if V8_TARGET_ARCH_ARM64 |
| 6 | 6 |
| 7 #include "src/arm64/frames-arm64.h" | 7 #include "src/arm64/frames-arm64.h" |
| 8 #include "src/codegen.h" | 8 #include "src/codegen.h" |
| 9 #include "src/debug/debug.h" | 9 #include "src/debug/debug.h" |
| 10 | 10 |
| (...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 67 patcher.b(&skip_constant); | 67 patcher.b(&skip_constant); |
| 68 patcher.dc64(reinterpret_cast<int64_t>(code->entry())); | 68 patcher.dc64(reinterpret_cast<int64_t>(code->entry())); |
| 69 patcher.bind(&skip_constant); | 69 patcher.bind(&skip_constant); |
| 70 // TODO(all): check the following is correct. | 70 // TODO(all): check the following is correct. |
| 71 // The debug break slot code will push a frame and call statically compiled | 71 // The debug break slot code will push a frame and call statically compiled |
| 72 // code. By using blr, this call site will be registered in the frame. | 72 // code. By using blr, this call site will be registered in the frame. |
| 73 // The debugger can now iterate on the frames to find this call. | 73 // The debugger can now iterate on the frames to find this call. |
| 74 patcher.blr(ip0); | 74 patcher.blr(ip0); |
| 75 } | 75 } |
| 76 | 76 |
| 77 bool DebugCodegen::DebugBreakSlotIsPatched(Address pc) { |
| 78 Instruction* current_instr = reinterpret_cast<Instruction*>(pc); |
| 79 return !current_instr->IsNop(Assembler::DEBUG_BREAK_NOP); |
| 80 } |
| 77 | 81 |
| 78 void DebugCodegen::GenerateDebugBreakStub(MacroAssembler* masm, | 82 void DebugCodegen::GenerateDebugBreakStub(MacroAssembler* masm, |
| 79 DebugBreakCallHelperMode mode) { | 83 DebugBreakCallHelperMode mode) { |
| 80 __ RecordComment("Debug break"); | 84 __ RecordComment("Debug break"); |
| 81 Register scratch = x10; | 85 Register scratch = x10; |
| 82 { | 86 { |
| 83 FrameScope scope(masm, StackFrame::INTERNAL); | 87 FrameScope scope(masm, StackFrame::INTERNAL); |
| 84 | 88 |
| 85 // Load padding words on stack. | 89 // Load padding words on stack. |
| 86 __ Mov(scratch, Smi::FromInt(LiveEdit::kFramePaddingValue)); | 90 __ Mov(scratch, Smi::FromInt(LiveEdit::kFramePaddingValue)); |
| (...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 152 __ Br(scratch); | 156 __ Br(scratch); |
| 153 } | 157 } |
| 154 | 158 |
| 155 | 159 |
| 156 const bool LiveEdit::kFrameDropperSupported = true; | 160 const bool LiveEdit::kFrameDropperSupported = true; |
| 157 | 161 |
| 158 } // namespace internal | 162 } // namespace internal |
| 159 } // namespace v8 | 163 } // namespace v8 |
| 160 | 164 |
| 161 #endif // V8_TARGET_ARCH_ARM64 | 165 #endif // V8_TARGET_ARCH_ARM64 |
| OLD | NEW |