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

Unified Diff: src/debug/debug.h

Issue 2033223003: [debug] implement intuitive semantics for stepping over await call. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: fix arm64 Created 4 years, 6 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/assembler.cc ('k') | src/debug/debug.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/debug/debug.h
diff --git a/src/debug/debug.h b/src/debug/debug.h
index 2cdc1515a6368b174556c3b3057313bcc2658c2b..3e6b384356ac9230a50cf86cebdc6eccecbbd8b5 100644
--- a/src/debug/debug.h
+++ b/src/debug/debug.h
@@ -456,6 +456,7 @@ class Debug {
// Stepping handling.
void PrepareStep(StepAction step_action);
void PrepareStepIn(Handle<JSFunction> function);
+ void PrepareStepInSuspendedGenerator();
void PrepareStepOnThrow();
void ClearStepping();
void ClearStepOut();
@@ -463,6 +464,8 @@ class Debug {
bool PrepareFunctionForBreakPoints(Handle<SharedFunctionInfo> shared);
+ void RecordAsyncFunction(Handle<JSGeneratorObject> generator_object);
+
// Returns whether the operation succeeded. Compilation can only be triggered
// if a valid closure is passed as the second argument, otherwise the shared
// function needs to be compiled already.
@@ -497,6 +500,7 @@ class Debug {
char* RestoreDebug(char* from);
static int ArchiveSpacePerThread();
void FreeThreadResources() { }
+ void Iterate(ObjectVisitor* v);
bool CheckExecutionState(int id) {
return is_active() && !debug_context().is_null() && break_id() != 0 &&
@@ -544,6 +548,10 @@ class Debug {
return reinterpret_cast<Address>(&thread_local_.step_in_enabled_);
}
+ Address suspended_generator_address() {
+ return reinterpret_cast<Address>(&thread_local_.suspended_generator_);
+ }
+
StepAction last_step_action() { return thread_local_.last_step_action_; }
DebugFeatureTracker* feature_tracker() { return &feature_tracker_; }
@@ -564,6 +572,14 @@ class Debug {
return break_disabled_ || in_debug_event_listener_;
}
+ void clear_suspended_generator() {
+ thread_local_.suspended_generator_ = Smi::FromInt(0);
+ }
+
+ bool has_suspended_generator() const {
+ return thread_local_.suspended_generator_ != Smi::FromInt(0);
+ }
+
void OnException(Handle<Object> exception, Handle<Object> promise);
// Constructors for debug event objects.
@@ -687,6 +703,8 @@ class Debug {
// Value of accumulator in interpreter frames. In non-interpreter frames
// this value will be the hole.
Handle<Object> return_value_;
+
+ Object* suspended_generator_;
};
// Storage location for registers when handling debug break calls
« no previous file with comments | « src/assembler.cc ('k') | src/debug/debug.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698