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" |
11 #include "vm/compiler.h" | 11 #include "vm/compiler.h" |
12 #include "vm/cpu.h" | 12 #include "vm/cpu.h" |
13 #include "vm/dart_entry.h" | 13 #include "vm/dart_entry.h" |
14 #include "vm/deopt_instructions.h" | 14 #include "vm/deopt_instructions.h" |
15 #include "vm/il_printer.h" | 15 #include "vm/il_printer.h" |
16 #include "vm/instructions.h" | 16 #include "vm/instructions.h" |
17 #include "vm/locations.h" | 17 #include "vm/locations.h" |
18 #include "vm/object_store.h" | 18 #include "vm/object_store.h" |
19 #include "vm/parser.h" | 19 #include "vm/parser.h" |
20 #include "vm/stack_frame.h" | 20 #include "vm/stack_frame.h" |
21 #include "vm/stub_code.h" | 21 #include "vm/stub_code.h" |
22 #include "vm/symbols.h" | 22 #include "vm/symbols.h" |
23 #include "vm/verified_memory.h" | |
24 | 23 |
25 namespace dart { | 24 namespace dart { |
26 | 25 |
27 DEFINE_FLAG(bool, trap_on_deoptimization, false, "Trap on deoptimization."); | 26 DEFINE_FLAG(bool, trap_on_deoptimization, false, "Trap on deoptimization."); |
28 DEFINE_FLAG(bool, unbox_mints, true, "Optimize 64-bit integer arithmetic."); | 27 DEFINE_FLAG(bool, unbox_mints, true, "Optimize 64-bit integer arithmetic."); |
29 DEFINE_FLAG(bool, unbox_doubles, true, "Optimize double arithmetic."); | 28 DEFINE_FLAG(bool, unbox_doubles, true, "Optimize double arithmetic."); |
30 DECLARE_FLAG(bool, enable_simd_inline); | 29 DECLARE_FLAG(bool, enable_simd_inline); |
31 DECLARE_FLAG(bool, use_megamorphic_stub); | 30 DECLARE_FLAG(bool, use_megamorphic_stub); |
32 | 31 |
33 | 32 |
(...skipping 1211 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1245 ASSERT(!edge_counters_array_.IsNull()); | 1244 ASSERT(!edge_counters_array_.IsNull()); |
1246 ASSERT(assembler_->constant_pool_allowed()); | 1245 ASSERT(assembler_->constant_pool_allowed()); |
1247 __ Comment("Edge counter"); | 1246 __ Comment("Edge counter"); |
1248 __ LoadObject(R0, edge_counters_array_); | 1247 __ LoadObject(R0, edge_counters_array_); |
1249 #if defined(DEBUG) | 1248 #if defined(DEBUG) |
1250 bool old_use_far_branches = assembler_->use_far_branches(); | 1249 bool old_use_far_branches = assembler_->use_far_branches(); |
1251 assembler_->set_use_far_branches(true); | 1250 assembler_->set_use_far_branches(true); |
1252 #endif // DEBUG | 1251 #endif // DEBUG |
1253 __ LoadFieldFromOffset(kWord, R1, R0, Array::element_offset(edge_id)); | 1252 __ LoadFieldFromOffset(kWord, R1, R0, Array::element_offset(edge_id)); |
1254 __ add(R1, R1, Operand(Smi::RawValue(1))); | 1253 __ add(R1, R1, Operand(Smi::RawValue(1))); |
1255 __ StoreIntoObjectNoBarrierOffset( | 1254 __ StoreIntoObjectNoBarrierOffset(R0, Array::element_offset(edge_id), R1); |
1256 R0, Array::element_offset(edge_id), R1, Assembler::kOnlySmi); | |
1257 #if defined(DEBUG) | 1255 #if defined(DEBUG) |
1258 assembler_->set_use_far_branches(old_use_far_branches); | 1256 assembler_->set_use_far_branches(old_use_far_branches); |
1259 #endif // DEBUG | 1257 #endif // DEBUG |
1260 } | 1258 } |
1261 | 1259 |
1262 | 1260 |
1263 void FlowGraphCompiler::EmitOptimizedInstanceCall( | 1261 void FlowGraphCompiler::EmitOptimizedInstanceCall( |
1264 const StubEntry& stub_entry, | 1262 const StubEntry& stub_entry, |
1265 const ICData& ic_data, | 1263 const ICData& ic_data, |
1266 intptr_t argument_count, | 1264 intptr_t argument_count, |
(...skipping 733 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2000 DRegister dreg = EvenDRegisterOf(reg); | 1998 DRegister dreg = EvenDRegisterOf(reg); |
2001 __ vldrd(dreg, Address(SP, kDoubleSize, Address::PostIndex)); | 1999 __ vldrd(dreg, Address(SP, kDoubleSize, Address::PostIndex)); |
2002 } | 2000 } |
2003 | 2001 |
2004 | 2002 |
2005 #undef __ | 2003 #undef __ |
2006 | 2004 |
2007 } // namespace dart | 2005 } // namespace dart |
2008 | 2006 |
2009 #endif // defined TARGET_ARCH_ARM | 2007 #endif // defined TARGET_ARCH_ARM |
OLD | NEW |