Index: runtime/vm/stub_code_x64.cc |
=================================================================== |
--- runtime/vm/stub_code_x64.cc (revision 24627) |
+++ runtime/vm/stub_code_x64.cc (working copy) |
@@ -1416,6 +1416,19 @@ |
} |
#endif // DEBUG |
+ // Check single stepping. |
+ Label not_stepping; |
+ __ movq(RAX, FieldAddress(CTX, Context::isolate_offset())); |
+ __ movzxb(RAX, Address(RAX, Isolate::single_step_offset())); |
+ __ cmpq(RAX, Immediate(0)); |
+ __ j(EQUAL, ¬_stepping, Assembler::kNearJump); |
+ __ EnterStubFrame(); |
+ __ pushq(RBX); |
+ __ CallRuntime(kSingleStepHandlerRuntimeEntry); |
+ __ popq(RBX); |
+ __ LeaveFrame(); |
+ __ Bind(¬_stepping); |
+ |
// Load arguments descriptor into R10. |
__ movq(R10, FieldAddress(RBX, ICData::arguments_descriptor_offset())); |
// Loop that checks if there is an IC data match. |
@@ -1636,6 +1649,19 @@ |
} |
#endif // DEBUG |
+ // Check single stepping. |
+ Label not_stepping; |
+ __ movq(RAX, FieldAddress(CTX, Context::isolate_offset())); |
+ __ movzxb(RAX, Address(RAX, Isolate::single_step_offset())); |
+ __ cmpq(RAX, Immediate(0)); |
+ __ j(EQUAL, ¬_stepping, Assembler::kNearJump); |
+ __ EnterStubFrame(); |
+ __ pushq(RBX); // Preserve IC data object. |
+ __ CallRuntime(kSingleStepHandlerRuntimeEntry); |
+ __ popq(RBX); |
+ __ LeaveFrame(); |
+ __ Bind(¬_stepping); |
+ |
// RBX: IC data object (preserved). |
__ movq(R12, FieldAddress(RBX, ICData::ic_data_offset())); |
// R12: ic_data_array with entries: target functions and count. |
@@ -2098,6 +2124,17 @@ |
// Returns ZF set. |
void StubCode::GenerateUnoptimizedIdenticalWithNumberCheckStub( |
Assembler* assembler) { |
+ // Check single stepping. |
+ Label not_stepping; |
+ __ movq(RAX, FieldAddress(CTX, Context::isolate_offset())); |
+ __ movzxb(RAX, Address(RAX, Isolate::single_step_offset())); |
+ __ cmpq(RAX, Immediate(0)); |
+ __ j(EQUAL, ¬_stepping, Assembler::kNearJump); |
+ __ EnterStubFrame(); |
+ __ CallRuntime(kSingleStepHandlerRuntimeEntry); |
+ __ LeaveFrame(); |
+ __ Bind(¬_stepping); |
+ |
const Register left = RAX; |
const Register right = RDX; |