diff options
Diffstat (limited to 'deps/v8/src/debug/ppc/debug-ppc.cc')
-rw-r--r-- | deps/v8/src/debug/ppc/debug-ppc.cc | 32 |
1 files changed, 13 insertions, 19 deletions
diff --git a/deps/v8/src/debug/ppc/debug-ppc.cc b/deps/v8/src/debug/ppc/debug-ppc.cc index ed4a632475..c5ddab8bc0 100644 --- a/deps/v8/src/debug/ppc/debug-ppc.cc +++ b/deps/v8/src/debug/ppc/debug-ppc.cc @@ -24,25 +24,25 @@ void EmitDebugBreakSlot(MacroAssembler* masm) { } -void DebugCodegen::GenerateSlot(MacroAssembler* masm, RelocInfo::Mode mode, - int call_argc) { +void DebugCodegen::GenerateSlot(MacroAssembler* masm, RelocInfo::Mode mode) { // Generate enough nop's to make space for a call instruction. Avoid emitting // the trampoline pool in the debug break slot code. Assembler::BlockTrampolinePoolScope block_trampoline_pool(masm); - masm->RecordDebugBreakSlot(mode, call_argc); + masm->RecordDebugBreakSlot(mode); EmitDebugBreakSlot(masm); } -void DebugCodegen::ClearDebugBreakSlot(Address pc) { - CodePatcher patcher(pc, Assembler::kDebugBreakSlotInstructions); +void DebugCodegen::ClearDebugBreakSlot(Isolate* isolate, Address pc) { + CodePatcher patcher(isolate, pc, Assembler::kDebugBreakSlotInstructions); EmitDebugBreakSlot(patcher.masm()); } -void DebugCodegen::PatchDebugBreakSlot(Address pc, Handle<Code> code) { +void DebugCodegen::PatchDebugBreakSlot(Isolate* isolate, Address pc, + Handle<Code> code) { DCHECK_EQ(Code::BUILTIN, code->kind()); - CodePatcher patcher(pc, Assembler::kDebugBreakSlotInstructions); + CodePatcher patcher(isolate, pc, Assembler::kDebugBreakSlotInstructions); // Patch the code changing the debug break slot code from // // ori r3, r3, 0 @@ -115,19 +115,7 @@ void DebugCodegen::GenerateDebugBreakStub(MacroAssembler* masm, } -void DebugCodegen::GeneratePlainReturnLiveEdit(MacroAssembler* masm) { - __ Ret(); -} - - void DebugCodegen::GenerateFrameDropperLiveEdit(MacroAssembler* masm) { - ExternalReference restarter_frame_function_slot = - ExternalReference::debug_restarter_frame_function_pointer_address( - masm->isolate()); - __ mov(ip, Operand(restarter_frame_function_slot)); - __ li(r4, Operand::Zero()); - __ StoreP(r4, MemOperand(ip, 0)); - // Load the function pointer off of our current stack frame. __ LoadP(r4, MemOperand(fp, StandardFrameConstants::kConstantPoolOffset - kPointerSize)); @@ -135,9 +123,15 @@ void DebugCodegen::GenerateFrameDropperLiveEdit(MacroAssembler* masm) { // Pop return address and frame __ LeaveFrame(StackFrame::INTERNAL); + ParameterCount dummy(0); + __ FloodFunctionIfStepping(r4, no_reg, dummy, dummy); + // Load context from the function. __ LoadP(cp, FieldMemOperand(r4, JSFunction::kContextOffset)); + // Clear new.target as a safety measure. + __ LoadRoot(r6, Heap::kUndefinedValueRootIndex); + // Get function code. __ LoadP(ip, FieldMemOperand(r4, JSFunction::kSharedFunctionInfoOffset)); __ LoadP(ip, FieldMemOperand(ip, SharedFunctionInfo::kCodeOffset)); |