| OLD | NEW |
| 1 // Copyright (c) 2016, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2016, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 #include "vm/globals.h" // Needed here to get TARGET_ARCH_DBC. | 5 #include "vm/globals.h" // Needed here to get TARGET_ARCH_DBC. |
| 6 #if defined(TARGET_ARCH_DBC) | 6 #if defined(TARGET_ARCH_DBC) |
| 7 | 7 |
| 8 #include "vm/flow_graph_compiler.h" | 8 #include "vm/flow_graph_compiler.h" |
| 9 | 9 |
| 10 #include "vm/ast_printer.h" | 10 #include "vm/ast_printer.h" |
| (...skipping 176 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 187 // Marks either the continuation point in unoptimized code or the | 187 // Marks either the continuation point in unoptimized code or the |
| 188 // deoptimization point in optimized code, after call. | 188 // deoptimization point in optimized code, after call. |
| 189 const intptr_t deopt_id_after = Thread::ToDeoptAfter(instr->deopt_id()); | 189 const intptr_t deopt_id_after = Thread::ToDeoptAfter(instr->deopt_id()); |
| 190 if (is_optimizing()) { | 190 if (is_optimizing()) { |
| 191 // Return/ReturnTOS instruction drops incoming arguments so | 191 // Return/ReturnTOS instruction drops incoming arguments so |
| 192 // we have to drop outgoing arguments from the innermost environment. | 192 // we have to drop outgoing arguments from the innermost environment. |
| 193 // On all other architectures caller drops outgoing arguments itself | 193 // On all other architectures caller drops outgoing arguments itself |
| 194 // hence the difference. | 194 // hence the difference. |
| 195 pending_deoptimization_env_->DropArguments(instr->ArgumentCount()); | 195 pending_deoptimization_env_->DropArguments(instr->ArgumentCount()); |
| 196 AddDeoptIndexAtCall(deopt_id_after); | 196 AddDeoptIndexAtCall(deopt_id_after); |
| 197 // This descriptor is needed for exception handling in optimized code. |
| 198 AddCurrentDescriptor(RawPcDescriptors::kOther, |
| 199 deopt_id_after, instr->token_pos()); |
| 197 } else { | 200 } else { |
| 198 // Add deoptimization continuation point after the call and before the | 201 // Add deoptimization continuation point after the call and before the |
| 199 // arguments are removed. | 202 // arguments are removed. |
| 200 // In optimized code this descriptor is needed for exception handling. | |
| 201 AddCurrentDescriptor(RawPcDescriptors::kDeopt, | 203 AddCurrentDescriptor(RawPcDescriptors::kDeopt, |
| 202 deopt_id_after, | 204 deopt_id_after, |
| 203 instr->token_pos()); | 205 instr->token_pos()); |
| 204 } | 206 } |
| 205 } | 207 } |
| 206 | 208 |
| 207 | 209 |
| 208 void CompilerDeoptInfoWithStub::GenerateCode(FlowGraphCompiler* compiler, | 210 void CompilerDeoptInfoWithStub::GenerateCode(FlowGraphCompiler* compiler, |
| 209 intptr_t stub_ix) { | 211 intptr_t stub_ix) { |
| 210 UNREACHABLE(); | 212 UNREACHABLE(); |
| (...skipping 349 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 560 void ParallelMoveResolver::RestoreFpuScratch(FpuRegister reg) { | 562 void ParallelMoveResolver::RestoreFpuScratch(FpuRegister reg) { |
| 561 UNIMPLEMENTED(); | 563 UNIMPLEMENTED(); |
| 562 } | 564 } |
| 563 | 565 |
| 564 | 566 |
| 565 #undef __ | 567 #undef __ |
| 566 | 568 |
| 567 } // namespace dart | 569 } // namespace dart |
| 568 | 570 |
| 569 #endif // defined TARGET_ARCH_DBC | 571 #endif // defined TARGET_ARCH_DBC |
| OLD | NEW |