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

Unified Diff: runtime/vm/code_generator.cc

Issue 1847623002: Ensure deoptimizing frames have a valid pc marker before deferred materialization. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: 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 | « no previous file | runtime/vm/deopt_instructions.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/code_generator.cc
diff --git a/runtime/vm/code_generator.cc b/runtime/vm/code_generator.cc
index bb7d5e07101ef6c16078be03916854870c7a036c..11b7f8c73c097e139a579c6dd0ac7b2e1174fd97 100644
--- a/runtime/vm/code_generator.cc
+++ b/runtime/vm/code_generator.cc
@@ -1793,6 +1793,17 @@ END_LEAF_RUNTIME_ENTRY
// materialization phase.
DEFINE_RUNTIME_ENTRY(DeoptimizeMaterialize, 0) {
#if !defined(DART_PRECOMPILED_RUNTIME)
+#if defined(DEBUG)
+ {
+ // We may rendezvous for a safepoint at entry or GC from the allocations
+ // below. Check the stack is walkable.
+ StackFrameIterator frames_iterator(StackFrameIterator::kValidateFrames);
+ StackFrame* frame = frames_iterator.NextFrame();
+ while (frame != NULL) {
+ frame = frames_iterator.NextFrame();
+ }
+ }
+#endif
DeoptContext* deopt_context = isolate->deopt_context();
intptr_t deopt_arg_count = deopt_context->MaterializeDeferredObjects();
isolate->set_deopt_context(NULL);
« no previous file with comments | « no previous file | runtime/vm/deopt_instructions.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698