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

Unified Diff: src/debug.cc

Issue 1038613002: [turbofan] Support initial step-in through debugger statement. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Follow-up after rebase. Created 5 years, 9 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/runtime/runtime-debug.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/debug.cc
diff --git a/src/debug.cc b/src/debug.cc
index ae9e284015ba3ea4f9ff93851afd11861bdfb2eb..c83ad4bf5961385a36513cc247a8c9b00746f687 100644
--- a/src/debug.cc
+++ b/src/debug.cc
@@ -1263,8 +1263,12 @@ void Debug::PrepareStep(StepAction step_action,
return;
}
+ List<FrameSummary> frames(FLAG_max_inlining_levels + 1);
+ frames_it.frame()->Summarize(&frames);
+ FrameSummary summary = frames.first();
+
// Get the debug info (create it if it does not exist).
- Handle<JSFunction> function(frame->function());
+ Handle<JSFunction> function(summary.function());
Handle<SharedFunctionInfo> shared(function->shared());
if (!EnsureDebugInfo(shared, function)) {
// Return if ensuring debug info failed.
@@ -1280,7 +1284,7 @@ void Debug::PrepareStep(StepAction step_action,
// PC points to the instruction after the current one, possibly a break
// location as well. So the "- 1" to exclude it from the search.
- Address call_pc = frame->pc() - 1;
+ Address call_pc = summary.pc() - 1;
BreakLocation location =
BreakLocation::FromAddress(debug_info, ALL_BREAK_LOCATIONS, call_pc);
@@ -1347,7 +1351,7 @@ void Debug::PrepareStep(StepAction step_action,
// Remember source position and frame to handle step next.
thread_local_.last_statement_position_ =
- debug_info->code()->SourceStatementPosition(frame->pc());
+ debug_info->code()->SourceStatementPosition(summary.pc());
thread_local_.last_fp_ = frame->UnpaddedFP();
} else {
// If there's restarter frame on top of the stack, just get the pointer
@@ -1419,7 +1423,7 @@ void Debug::PrepareStep(StepAction step_action,
// Object::Get/SetPropertyWithAccessor, otherwise the step action will be
// propagated on the next Debug::Break.
thread_local_.last_statement_position_ =
- debug_info->code()->SourceStatementPosition(frame->pc());
+ debug_info->code()->SourceStatementPosition(summary.pc());
thread_local_.last_fp_ = frame->UnpaddedFP();
}
« no previous file with comments | « no previous file | src/runtime/runtime-debug.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698