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

Unified Diff: src/debug.h

Issue 301563004: Refactor after break target computation. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 7 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 | « no previous file | src/debug.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/debug.h
diff --git a/src/debug.h b/src/debug.h
index e6c1d262d4e6cb1f5760537ecf2afdeedacce569..e63af4aa097b991efb5214e7f9a1399c89c85028 100644
--- a/src/debug.h
+++ b/src/debug.h
@@ -413,7 +413,8 @@ class Debug {
bool IsLoaded() { return !debug_context_.is_null(); }
bool InDebugger() { return thread_local_.debugger_entry_ != NULL; }
- Object* Break(Arguments args);
+ void Break(Arguments args, JavaScriptFrame*);
+ void SetAfterBreakTarget(JavaScriptFrame* frame);
bool SetBreakPoint(Handle<JSFunction> function,
Handle<Object> break_point_object,
int* source_position);
@@ -539,7 +540,7 @@ class Debug {
// Support for setting the address to jump to when returning from break point.
Address after_break_target_address() {
- return reinterpret_cast<Address>(&thread_local_.after_break_target_);
+ return reinterpret_cast<Address>(&after_break_target_);
}
Address restarter_frame_function_pointer_address() {
@@ -634,7 +635,6 @@ class Debug {
void ClearStepNext();
// Returns whether the compile succeeded.
void RemoveDebugInfo(Handle<DebugInfo> debug_info);
- void SetAfterBreakTarget(JavaScriptFrame* frame);
Handle<Object> CheckBreakPoints(Handle<Object> break_point);
bool CheckBreakPoint(Handle<Object> break_point_object);
@@ -683,6 +683,11 @@ class Debug {
ScriptCache* script_cache_; // Cache of all scripts in the heap.
DebugInfoListNode* debug_info_list_; // List of active debug info objects.
+ // Storage location for jump when exiting debug break calls.
+ // Note that this address is not GC safe. It should be computed immediately
+ // before returning to the DebugBreakCallHelper.
+ Address after_break_target_;
+
// Per-thread data.
class ThreadLocal {
public:
@@ -720,9 +725,6 @@ class Debug {
// step out action is completed.
Address step_out_fp_;
- // Storage location for jump when exiting debug break calls.
- Address after_break_target_;
-
// Pending interrupts scheduled while debugging.
bool has_pending_interrupt_;
« no previous file with comments | « no previous file | src/debug.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698