Index: src/runtime/runtime-compiler.cc |
diff --git a/src/runtime/runtime-compiler.cc b/src/runtime/runtime-compiler.cc |
index f1c76bb2acc5734cc629d26784b5eb58b838d12b..699c4c3a6e8add0ed2d3943d2972b2c5bd975fc5 100644 |
--- a/src/runtime/runtime-compiler.cc |
+++ b/src/runtime/runtime-compiler.cc |
@@ -182,6 +182,10 @@ RUNTIME_FUNCTION(Runtime_NotifyDeoptimized) { |
JavaScriptFrameIterator top_it(isolate); |
JavaScriptFrame* top_frame = top_it.frame(); |
isolate->set_context(Context::cast(top_frame->context())); |
+ } else { |
+ // TODO(turbofan): We currently need the native context to materialize |
+ // the arguments object, but only to get to its map. |
+ isolate->set_context(function->native_context()); |
} |
// Make sure to materialize objects before causing any allocation. |