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 1314 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1325 __ add(IP, R2, Operand(R3, LSL, 2)); | 1325 __ add(IP, R2, Operand(R3, LSL, 2)); |
1326 __ ldr(R0, FieldAddress(IP, base + kWordSize)); | 1326 __ ldr(R0, FieldAddress(IP, base + kWordSize)); |
1327 __ ldr(R1, FieldAddress(R0, Function::instructions_offset())); | 1327 __ ldr(R1, FieldAddress(R0, Function::instructions_offset())); |
1328 __ LoadObject(R5, ic_data); | 1328 __ LoadObject(R5, ic_data); |
1329 __ LoadObject(R4, arguments_descriptor); | 1329 __ LoadObject(R4, arguments_descriptor); |
1330 __ AddImmediate(R1, Instructions::HeaderSize() - kHeapObjectTag); | 1330 __ AddImmediate(R1, Instructions::HeaderSize() - kHeapObjectTag); |
1331 __ blx(R1); | 1331 __ blx(R1); |
1332 AddCurrentDescriptor(RawPcDescriptors::kOther, | 1332 AddCurrentDescriptor(RawPcDescriptors::kOther, |
1333 Isolate::kNoDeoptId, token_pos); | 1333 Isolate::kNoDeoptId, token_pos); |
1334 RecordSafepoint(locs); | 1334 RecordSafepoint(locs); |
1335 AddDeoptIndexAtCall(Isolate::ToDeoptAfter(deopt_id), token_pos); | 1335 const intptr_t deopt_id_after = Isolate::ToDeoptAfter(deopt_id); |
| 1336 if (is_optimizing()) { |
| 1337 AddDeoptIndexAtCall(deopt_id_after, token_pos); |
| 1338 } else { |
| 1339 // Add deoptimization continuation point after the call and before the |
| 1340 // arguments are removed. |
| 1341 AddCurrentDescriptor(RawPcDescriptors::kDeopt, |
| 1342 deopt_id_after, token_pos); |
| 1343 } |
1336 __ Drop(argument_count); | 1344 __ Drop(argument_count); |
1337 } | 1345 } |
1338 | 1346 |
1339 | 1347 |
1340 void FlowGraphCompiler::EmitUnoptimizedStaticCall( | 1348 void FlowGraphCompiler::EmitUnoptimizedStaticCall( |
1341 intptr_t argument_count, | 1349 intptr_t argument_count, |
1342 intptr_t deopt_id, | 1350 intptr_t deopt_id, |
1343 intptr_t token_pos, | 1351 intptr_t token_pos, |
1344 LocationSummary* locs, | 1352 LocationSummary* locs, |
1345 const ICData& ic_data) { | 1353 const ICData& ic_data) { |
(...skipping 529 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1875 DRegister dreg = EvenDRegisterOf(reg); | 1883 DRegister dreg = EvenDRegisterOf(reg); |
1876 __ vldrd(dreg, Address(SP, kDoubleSize, Address::PostIndex)); | 1884 __ vldrd(dreg, Address(SP, kDoubleSize, Address::PostIndex)); |
1877 } | 1885 } |
1878 | 1886 |
1879 | 1887 |
1880 #undef __ | 1888 #undef __ |
1881 | 1889 |
1882 } // namespace dart | 1890 } // namespace dart |
1883 | 1891 |
1884 #endif // defined TARGET_ARCH_ARM | 1892 #endif // defined TARGET_ARCH_ARM |
OLD | NEW |