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

Unified Diff: runtime/vm/stack_frame.cc

Issue 2571843002: VM: [DBC] Fix GetDeoptFpOffset in the presence of materializations. (Closed)
Patch Set: Created 4 years 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 | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/stack_frame.cc
diff --git a/runtime/vm/stack_frame.cc b/runtime/vm/stack_frame.cc
index f21ad3e4864e5b87a27f6ab0947daa9409259044..500e1ea10dad9f21a87330456c72ce8b63eeab14 100644
--- a/runtime/vm/stack_frame.cc
+++ b/runtime/vm/stack_frame.cc
@@ -552,14 +552,14 @@ intptr_t InlinedFunctionsIterator::GetDeoptFpOffset() const {
for (intptr_t index = index_; index < deopt_instructions_.length(); index++) {
DeoptInstr* deopt_instr = deopt_instructions_[index];
if (deopt_instr->kind() == DeoptInstr::kCallerFp) {
+ intptr_t fp_offset = (index - num_materializations_);
#if defined(TARGET_ARCH_DBC)
// Stack on DBC is growing upwards but we record deopt commands
// in the same order we record them on other architectures as if
// the stack was growing downwards.
- return dest_frame_size_ - index;
-#else
- return (index - num_materializations_);
+ fp_offset = dest_frame_size_ - fp_offset;
#endif
+ return fp_offset;
}
}
UNREACHABLE();
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698