Chromium Code Reviews| Index: runtime/vm/intermediate_language_dbc.cc |
| diff --git a/runtime/vm/intermediate_language_dbc.cc b/runtime/vm/intermediate_language_dbc.cc |
| index 0dda8e1f41979c5293c2376848d8a18402adec07..b4f8e0527ed9ae88cacc34977ed4f2f261fba0a0 100644 |
| --- a/runtime/vm/intermediate_language_dbc.cc |
| +++ b/runtime/vm/intermediate_language_dbc.cc |
| @@ -273,10 +273,23 @@ EMIT_NATIVE_CODE(CheckStackOverflow, |
| 0, Location::NoLocation(), |
| LocationSummary::kCall) { |
| __ CheckStack(); |
| - compiler->RecordSafepoint(locs()); |
| - compiler->AddCurrentDescriptor(RawPcDescriptors::kRuntimeCall, |
| - Thread::kNoDeoptId, |
| + compiler->AddCurrentDescriptor(RawPcDescriptors::kOther, |
| + deopt_id(), |
| token_pos()); |
| + compiler->RecordSafepoint(locs()); |
|
zra
2016/07/27 17:22:06
See if you can do FlowGraphCompiler::RecordAfterCa
rmacnak
2016/07/27 17:47:57
Yes, much better.
|
| + ASSERT(deopt_id() != Thread::kNoDeoptId); |
| + const intptr_t deopt_id_after = Thread::ToDeoptAfter(deopt_id()); |
| + // Marks either the continuation point in unoptimized code or the |
| + // deoptimization point in optimized code, after call. |
| + if (compiler->is_optimizing()) { |
| + compiler->AddDeoptIndexAtCall(deopt_id_after, token_pos()); |
| + } else { |
| + // Add deoptimization continuation point after the call and before the |
| + // arguments are removed. |
| + compiler->AddCurrentDescriptor(RawPcDescriptors::kDeopt, |
| + deopt_id_after, |
| + token_pos()); |
| + } |
| } |