Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(258)

Side by Side Diff: runtime/vm/flow_graph_compiler_arm.cc

Issue 1731743003: Move precompilation-related flags to flags list. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: make print_stop_message default false to fix build Created 4 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « runtime/vm/flow_graph_compiler.cc ('k') | runtime/vm/flow_graph_compiler_arm64.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 11 matching lines...) Expand all
22 #include "vm/symbols.h" 22 #include "vm/symbols.h"
23 #include "vm/verified_memory.h" 23 #include "vm/verified_memory.h"
24 24
25 namespace dart { 25 namespace dart {
26 26
27 DEFINE_FLAG(bool, trap_on_deoptimization, false, "Trap on deoptimization."); 27 DEFINE_FLAG(bool, trap_on_deoptimization, false, "Trap on deoptimization.");
28 DEFINE_FLAG(bool, unbox_mints, true, "Optimize 64-bit integer arithmetic."); 28 DEFINE_FLAG(bool, unbox_mints, true, "Optimize 64-bit integer arithmetic.");
29 DEFINE_FLAG(bool, unbox_doubles, true, "Optimize double arithmetic."); 29 DEFINE_FLAG(bool, unbox_doubles, true, "Optimize double arithmetic.");
30 DECLARE_FLAG(bool, enable_simd_inline); 30 DECLARE_FLAG(bool, enable_simd_inline);
31 DECLARE_FLAG(bool, use_megamorphic_stub); 31 DECLARE_FLAG(bool, use_megamorphic_stub);
32 DECLARE_FLAG(bool, precompilation);
33 32
34 33
35 void MegamorphicSlowPath::EmitNativeCode(FlowGraphCompiler* compiler) { 34 void MegamorphicSlowPath::EmitNativeCode(FlowGraphCompiler* compiler) {
36 Assembler* assembler = compiler->assembler(); 35 Assembler* assembler = compiler->assembler();
37 #define __ assembler-> 36 #define __ assembler->
38 __ Bind(entry_label()); 37 __ Bind(entry_label());
39 __ Comment("MegamorphicSlowPath"); 38 __ Comment("MegamorphicSlowPath");
40 compiler->EmitMegamorphicInstanceCall(ic_data_, argument_count_, deopt_id_, 39 compiler->EmitMegamorphicInstanceCall(ic_data_, argument_count_, deopt_id_,
41 token_pos_, locs_, try_index_); 40 token_pos_, locs_, try_index_);
42 __ b(exit_label()); 41 __ b(exit_label());
(...skipping 1084 matching lines...) Expand 10 before | Expand all | Expand 10 after
1127 } 1126 }
1128 } 1127 }
1129 } 1128 }
1130 1129
1131 VisitBlocks(); 1130 VisitBlocks();
1132 1131
1133 __ bkpt(0); 1132 __ bkpt(0);
1134 ASSERT(assembler()->constant_pool_allowed()); 1133 ASSERT(assembler()->constant_pool_allowed());
1135 GenerateDeferredCode(); 1134 GenerateDeferredCode();
1136 1135
1137 if (is_optimizing() && !FLAG_precompilation) { 1136 if (is_optimizing() && !FLAG_precompiled_mode) {
1138 // Leave enough space for patching in case of lazy deoptimization from 1137 // Leave enough space for patching in case of lazy deoptimization from
1139 // deferred code. 1138 // deferred code.
1140 for (intptr_t i = 0; 1139 for (intptr_t i = 0;
1141 i < CallPattern::DeoptCallPatternLengthInInstructions(); 1140 i < CallPattern::DeoptCallPatternLengthInInstructions();
1142 ++i) { 1141 ++i) {
1143 __ nop(); 1142 __ nop();
1144 } 1143 }
1145 lazy_deopt_pc_offset_ = assembler()->CodeSize(); 1144 lazy_deopt_pc_offset_ = assembler()->CodeSize();
1146 __ Branch(*StubCode::DeoptimizeLazy_entry()); 1145 __ Branch(*StubCode::DeoptimizeLazy_entry());
1147 } 1146 }
(...skipping 172 matching lines...) Expand 10 before | Expand all | Expand 10 after
1320 __ LoadObject(R9, cache); 1319 __ LoadObject(R9, cache);
1321 if (FLAG_use_megamorphic_stub) { 1320 if (FLAG_use_megamorphic_stub) {
1322 __ BranchLink(*StubCode::MegamorphicLookup_entry()); 1321 __ BranchLink(*StubCode::MegamorphicLookup_entry());
1323 } else { 1322 } else {
1324 StubCode::EmitMegamorphicLookup(assembler()); 1323 StubCode::EmitMegamorphicLookup(assembler());
1325 } 1324 }
1326 __ blx(R1); 1325 __ blx(R1);
1327 1326
1328 RecordSafepoint(locs); 1327 RecordSafepoint(locs);
1329 const intptr_t deopt_id_after = Thread::ToDeoptAfter(deopt_id); 1328 const intptr_t deopt_id_after = Thread::ToDeoptAfter(deopt_id);
1330 if (FLAG_precompilation) { 1329 if (FLAG_precompiled_mode) {
1331 // Megamorphic calls may occur in slow path stubs. 1330 // Megamorphic calls may occur in slow path stubs.
1332 // If valid use try_index argument. 1331 // If valid use try_index argument.
1333 if (try_index == CatchClauseNode::kInvalidTryIndex) { 1332 if (try_index == CatchClauseNode::kInvalidTryIndex) {
1334 try_index = CurrentTryIndex(); 1333 try_index = CurrentTryIndex();
1335 } 1334 }
1336 pc_descriptors_list()->AddDescriptor(RawPcDescriptors::kOther, 1335 pc_descriptors_list()->AddDescriptor(RawPcDescriptors::kOther,
1337 assembler()->CodeSize(), 1336 assembler()->CodeSize(),
1338 Thread::kNoDeoptId, 1337 Thread::kNoDeoptId,
1339 token_pos, 1338 token_pos,
1340 try_index); 1339 try_index);
(...skipping 633 matching lines...) Expand 10 before | Expand all | Expand 10 after
1974 DRegister dreg = EvenDRegisterOf(reg); 1973 DRegister dreg = EvenDRegisterOf(reg);
1975 __ vldrd(dreg, Address(SP, kDoubleSize, Address::PostIndex)); 1974 __ vldrd(dreg, Address(SP, kDoubleSize, Address::PostIndex));
1976 } 1975 }
1977 1976
1978 1977
1979 #undef __ 1978 #undef __
1980 1979
1981 } // namespace dart 1980 } // namespace dart
1982 1981
1983 #endif // defined TARGET_ARCH_ARM 1982 #endif // defined TARGET_ARCH_ARM
OLDNEW
« no previous file with comments | « runtime/vm/flow_graph_compiler.cc ('k') | runtime/vm/flow_graph_compiler_arm64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698