Index: src/execution.cc |
diff --git a/src/execution.cc b/src/execution.cc |
index fb2444c20af96b257c9de1570ef61c0a09efd2b7..1c8b0b9bb80a8ba5d96a6218f1525ceaa4e8c557 100644 |
--- a/src/execution.cc |
+++ b/src/execution.cc |
@@ -654,60 +654,6 @@ Handle<String> Execution::GetStackTraceLine(Handle<Object> recv, |
} |
-void Execution::DebugBreakHelper(Isolate* isolate) { |
- // Just continue if breaks are disabled. |
- if (isolate->debug()->disable_break()) return; |
- |
- // Ignore debug break during bootstrapping. |
- if (isolate->bootstrapper()->IsActive()) return; |
- |
- // Ignore debug break if debugger is not active. |
- if (!isolate->debug()->is_active()) return; |
- |
- StackLimitCheck check(isolate); |
- if (check.HasOverflowed()) return; |
- |
- { JavaScriptFrameIterator it(isolate); |
- ASSERT(!it.done()); |
- Object* fun = it.frame()->function(); |
- if (fun && fun->IsJSFunction()) { |
- // Don't stop in builtin functions. |
- if (JSFunction::cast(fun)->IsBuiltin()) return; |
- GlobalObject* global = JSFunction::cast(fun)->context()->global_object(); |
- // Don't stop in debugger functions. |
- if (isolate->debug()->IsDebugGlobal(global)) return; |
- } |
- } |
- |
- // Collect the break state before clearing the flags. |
- bool debug_command_only = isolate->stack_guard()->CheckDebugCommand() && |
- !isolate->stack_guard()->CheckDebugBreak(); |
- |
- isolate->stack_guard()->ClearDebugBreak(); |
- |
- Execution::ProcessDebugMessages(isolate, debug_command_only); |
-} |
- |
- |
-void Execution::ProcessDebugMessages(Isolate* isolate, |
- bool debug_command_only) { |
- isolate->stack_guard()->ClearDebugCommand(); |
- |
- StackLimitCheck check(isolate); |
- if (check.HasOverflowed()) return; |
- |
- HandleScope scope(isolate); |
- // Enter the debugger. Just continue if we fail to enter the debugger. |
- EnterDebugger debugger(isolate); |
- if (debugger.FailedToEnter()) return; |
- |
- // Notify the debug event listeners. Indicate auto continue if the break was |
- // a debug command break. |
- isolate->debug()->OnDebugBreak(isolate->factory()->undefined_value(), |
- debug_command_only); |
-} |
- |
- |
Object* StackGuard::HandleInterrupts() { |
bool has_api_interrupt = false; |
{ |
@@ -721,7 +667,7 @@ Object* StackGuard::HandleInterrupts() { |
} |
if (CheckDebugBreak() || CheckDebugCommand()) { |
- Execution::DebugBreakHelper(isolate_); |
+ isolate_->debug()->DebugBreakHelper(); |
} |
if (CheckAndClearInterrupt(TERMINATE_EXECUTION, access)) { |