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

Unified Diff: src/frames.cc

Issue 1763783003: [Interpreter] Fixes translation from bailout id to code offset. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Added comments Created 4 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 | « src/deoptimizer.cc ('k') | test/mjsunit/mjsunit.status » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/frames.cc
diff --git a/src/frames.cc b/src/frames.cc
index c4653c61e29f03ba0055841d99b0c862fca280ba..b76a4782d313adaa0b835bcacc48dcad0d4f8a59 100644
--- a/src/frames.cc
+++ b/src/frames.cc
@@ -1013,7 +1013,9 @@ void OptimizedFrame::Summarize(List<FrameSummary>* frames) {
abstract_code = AbstractCode::cast(code);
} else {
DCHECK_EQ(frame_opcode, Translation::INTERPRETED_FRAME);
- code_offset = bailout_id.ToInt();
+ // BailoutId points to the next bytecode in the bytecode aray. Subtract
+ // 1 to get the end of current bytecode.
+ code_offset = bailout_id.ToInt() - 1;
abstract_code = AbstractCode::cast(shared_info->bytecode_array());
}
FrameSummary summary(receiver, function, abstract_code, code_offset,
« no previous file with comments | « src/deoptimizer.cc ('k') | test/mjsunit/mjsunit.status » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698