Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(4)

Unified Diff: src/execution.cc

Issue 256653004: Always include debugger support. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Makefile Created 6 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/execution.h ('k') | src/factory.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/execution.cc
diff --git a/src/execution.cc b/src/execution.cc
index 3ca42fbd510130216b44c66f56ddc7c4e6ad7de0..961fd3cb49ecbd6a940860ba85bf607823f48221 100644
--- a/src/execution.cc
+++ b/src/execution.cc
@@ -103,12 +103,10 @@ MUST_USE_RESULT static MaybeHandle<Object> Invoke(
ASSERT(has_exception == isolate->has_pending_exception());
if (has_exception) {
isolate->ReportPendingMessages();
-#ifdef ENABLE_DEBUGGER_SUPPORT
// Reset stepping state when script exits with uncaught exception.
if (isolate->debugger()->IsDebuggerActive()) {
isolate->debug()->ClearStepping();
}
-#endif // ENABLE_DEBUGGER_SUPPORT
return MaybeHandle<Object>();
} else {
isolate->clear_pending_message();
@@ -478,7 +476,6 @@ void StackGuard::DeoptMarkedAllocationSites() {
}
-#ifdef ENABLE_DEBUGGER_SUPPORT
bool StackGuard::IsDebugBreak() {
ExecutionAccess access(isolate_);
return thread_local_.interrupt_flags_ & DEBUGBREAK;
@@ -503,7 +500,7 @@ void StackGuard::DebugCommand() {
thread_local_.interrupt_flags_ |= DEBUGCOMMAND;
set_interrupt_limits(access);
}
-#endif
+
void StackGuard::Continue(InterruptFlag after_what) {
ExecutionAccess access(isolate_);
@@ -841,7 +838,6 @@ static Object* RuntimePreempt(Isolate* isolate) {
// Clear the preempt request flag.
isolate->stack_guard()->Continue(PREEMPT);
-#ifdef ENABLE_DEBUGGER_SUPPORT
if (isolate->debug()->InDebugger()) {
// If currently in the debugger don't do any actual preemption but record
// that preemption occoured while in the debugger.
@@ -851,19 +847,11 @@ static Object* RuntimePreempt(Isolate* isolate) {
v8::Unlocker unlocker(reinterpret_cast<v8::Isolate*>(isolate));
Thread::YieldCPU();
}
-#else
- { // NOLINT
- // Perform preemption.
- v8::Unlocker unlocker(reinterpret_cast<v8::Isolate*>(isolate));
- Thread::YieldCPU();
- }
-#endif
return isolate->heap()->undefined_value();
}
-#ifdef ENABLE_DEBUGGER_SUPPORT
Object* Execution::DebugBreakHelper(Isolate* isolate) {
// Just continue if breaks are disabled.
if (isolate->debug()->disable_break()) {
@@ -939,7 +927,7 @@ void Execution::ProcessDebugMessages(Isolate* isolate,
isolate->debugger()->OnDebugBreak(isolate->factory()->undefined_value(),
debug_command_only);
}
-#endif
+
Object* Execution::HandleStackGuardInterrupt(Isolate* isolate) {
StackGuard* stack_guard = isolate->stack_guard();
@@ -960,11 +948,9 @@ Object* Execution::HandleStackGuardInterrupt(Isolate* isolate) {
isolate->counters()->stack_interrupts()->Increment();
isolate->counters()->runtime_profiler_ticks()->Increment();
-#ifdef ENABLE_DEBUGGER_SUPPORT
if (stack_guard->IsDebugBreak() || stack_guard->IsDebugCommand()) {
DebugBreakHelper(isolate);
}
-#endif
if (stack_guard->IsPreempted()) RuntimePreempt(isolate);
if (stack_guard->IsTerminateExecution()) {
stack_guard->Continue(TERMINATE);
« no previous file with comments | « src/execution.h ('k') | src/factory.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698