Index: runtime/vm/stub_code_arm.cc |
=================================================================== |
--- runtime/vm/stub_code_arm.cc (revision 36530) |
+++ runtime/vm/stub_code_arm.cc (working copy) |
@@ -27,6 +27,7 @@ |
"Set to true for debugging & verifying the slow paths."); |
DECLARE_FLAG(bool, trace_optimized_ic_calls); |
+DECLARE_FLAG(bool, enable_debugger); |
// Input parameters: |
// LR : return address. |
@@ -1268,18 +1269,20 @@ |
} |
#endif // DEBUG |
- // Check single stepping. |
- Label not_stepping; |
- __ ldr(R6, FieldAddress(CTX, Context::isolate_offset())); |
- __ ldrb(R6, Address(R6, Isolate::single_step_offset())); |
- __ CompareImmediate(R6, 0); |
- __ b(¬_stepping, EQ); |
- __ EnterStubFrame(); |
- __ Push(R5); // Preserve IC data. |
- __ CallRuntime(kSingleStepHandlerRuntimeEntry, 0); |
- __ Pop(R5); |
- __ LeaveStubFrame(); |
- __ Bind(¬_stepping); |
+ if (FLAG_enable_debugger) { |
+ // Check single stepping. |
+ Label not_stepping; |
+ __ ldr(R6, FieldAddress(CTX, Context::isolate_offset())); |
+ __ ldrb(R6, Address(R6, Isolate::single_step_offset())); |
+ __ CompareImmediate(R6, 0); |
+ __ b(¬_stepping, EQ); |
+ __ EnterStubFrame(); |
+ __ Push(R5); // Preserve IC data. |
+ __ CallRuntime(kSingleStepHandlerRuntimeEntry, 0); |
+ __ Pop(R5); |
+ __ LeaveStubFrame(); |
+ __ Bind(¬_stepping); |
+ } |
// Load arguments descriptor into R4. |
__ ldr(R4, FieldAddress(R5, ICData::arguments_descriptor_offset())); |