| OLD | NEW |
| 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2013, 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_ARM. | 5 #include "vm/globals.h" // Needed here to get TARGET_ARCH_ARM. |
| 6 #if defined(TARGET_ARCH_ARM) | 6 #if defined(TARGET_ARCH_ARM) |
| 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 40 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 51 | 51 |
| 52 | 52 |
| 53 bool FlowGraphCompiler::SupportsSinCos() { | 53 bool FlowGraphCompiler::SupportsSinCos() { |
| 54 return false; | 54 return false; |
| 55 } | 55 } |
| 56 | 56 |
| 57 | 57 |
| 58 RawDeoptInfo* CompilerDeoptInfo::CreateDeoptInfo(FlowGraphCompiler* compiler, | 58 RawDeoptInfo* CompilerDeoptInfo::CreateDeoptInfo(FlowGraphCompiler* compiler, |
| 59 DeoptInfoBuilder* builder, | 59 DeoptInfoBuilder* builder, |
| 60 const Array& deopt_table) { | 60 const Array& deopt_table) { |
| 61 if (deopt_env_ == NULL) return DeoptInfo::null(); | 61 if (deopt_env_ == NULL) { |
| 62 return DeoptInfo::null(); |
| 63 } |
| 62 | 64 |
| 63 intptr_t stack_height = compiler->StackSize(); | 65 intptr_t stack_height = compiler->StackSize(); |
| 64 AllocateIncomingParametersRecursive(deopt_env_, &stack_height); | 66 AllocateIncomingParametersRecursive(deopt_env_, &stack_height); |
| 65 | 67 |
| 66 intptr_t slot_ix = 0; | 68 intptr_t slot_ix = 0; |
| 67 Environment* current = deopt_env_; | 69 Environment* current = deopt_env_; |
| 68 | 70 |
| 69 // Emit all kMaterializeObject instructions describing objects to be | 71 // Emit all kMaterializeObject instructions describing objects to be |
| 70 // materialized on the deoptimization as a prefix to the deoptimization info. | 72 // materialized on the deoptimization as a prefix to the deoptimization info. |
| 71 EmitMaterializations(deopt_env_, builder); | 73 EmitMaterializations(deopt_env_, builder); |
| (...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 153 | 155 |
| 154 | 156 |
| 155 void CompilerDeoptInfoWithStub::GenerateCode(FlowGraphCompiler* compiler, | 157 void CompilerDeoptInfoWithStub::GenerateCode(FlowGraphCompiler* compiler, |
| 156 intptr_t stub_ix) { | 158 intptr_t stub_ix) { |
| 157 // Calls do not need stubs, they share a deoptimization trampoline. | 159 // Calls do not need stubs, they share a deoptimization trampoline. |
| 158 ASSERT(reason() != ICData::kDeoptAtCall); | 160 ASSERT(reason() != ICData::kDeoptAtCall); |
| 159 Assembler* assem = compiler->assembler(); | 161 Assembler* assem = compiler->assembler(); |
| 160 #define __ assem-> | 162 #define __ assem-> |
| 161 __ Comment("Deopt stub for id %" Pd "", deopt_id()); | 163 __ Comment("Deopt stub for id %" Pd "", deopt_id()); |
| 162 __ Bind(entry_label()); | 164 __ Bind(entry_label()); |
| 163 if (FLAG_trap_on_deoptimization) __ bkpt(0); | 165 if (FLAG_trap_on_deoptimization) { |
| 166 __ bkpt(0); |
| 167 } |
| 164 | 168 |
| 165 ASSERT(deopt_env() != NULL); | 169 ASSERT(deopt_env() != NULL); |
| 166 | 170 |
| 167 __ BranchLink(&StubCode::DeoptimizeLabel()); | 171 __ BranchLink(&StubCode::DeoptimizeLabel()); |
| 168 set_pc_offset(assem->CodeSize()); | 172 set_pc_offset(assem->CodeSize()); |
| 169 #undef __ | 173 #undef __ |
| 170 } | 174 } |
| 171 | 175 |
| 172 | 176 |
| 173 #define __ assembler()-> | 177 #define __ assembler()-> |
| (...skipping 1620 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1794 DRegister dreg = EvenDRegisterOf(reg); | 1798 DRegister dreg = EvenDRegisterOf(reg); |
| 1795 __ vldrd(dreg, Address(SP, kDoubleSize, Address::PostIndex)); | 1799 __ vldrd(dreg, Address(SP, kDoubleSize, Address::PostIndex)); |
| 1796 } | 1800 } |
| 1797 | 1801 |
| 1798 | 1802 |
| 1799 #undef __ | 1803 #undef __ |
| 1800 | 1804 |
| 1801 } // namespace dart | 1805 } // namespace dart |
| 1802 | 1806 |
| 1803 #endif // defined TARGET_ARCH_ARM | 1807 #endif // defined TARGET_ARCH_ARM |
| OLD | NEW |