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

Side by Side Diff: runtime/vm/flow_graph_compiler_ia32.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, 10 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_arm64.cc ('k') | runtime/vm/flow_graph_compiler_mips.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_IA32. 5 #include "vm/globals.h" // Needed here to get TARGET_ARCH_IA32.
6 #if defined(TARGET_ARCH_IA32) 6 #if defined(TARGET_ARCH_IA32)
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 13 matching lines...) Expand all
24 #include "vm/symbols.h" 24 #include "vm/symbols.h"
25 #include "vm/verified_memory.h" 25 #include "vm/verified_memory.h"
26 26
27 namespace dart { 27 namespace dart {
28 28
29 DEFINE_FLAG(bool, trap_on_deoptimization, false, "Trap on deoptimization."); 29 DEFINE_FLAG(bool, trap_on_deoptimization, false, "Trap on deoptimization.");
30 DEFINE_FLAG(bool, unbox_mints, true, "Optimize 64-bit integer arithmetic."); 30 DEFINE_FLAG(bool, unbox_mints, true, "Optimize 64-bit integer arithmetic.");
31 31
32 DECLARE_FLAG(bool, enable_simd_inline); 32 DECLARE_FLAG(bool, enable_simd_inline);
33 DECLARE_FLAG(bool, use_megamorphic_stub); 33 DECLARE_FLAG(bool, use_megamorphic_stub);
34 DECLARE_FLAG(bool, precompilation);
35 34
36 35
37 void MegamorphicSlowPath::EmitNativeCode(FlowGraphCompiler* compiler) { 36 void MegamorphicSlowPath::EmitNativeCode(FlowGraphCompiler* compiler) {
38 Assembler* assembler = compiler->assembler(); 37 Assembler* assembler = compiler->assembler();
39 #define __ assembler-> 38 #define __ assembler->
40 __ Bind(entry_label()); 39 __ Bind(entry_label());
41 __ Comment("MegamorphicSlowPath"); 40 __ Comment("MegamorphicSlowPath");
42 compiler->EmitMegamorphicInstanceCall(ic_data_, argument_count_, deopt_id_, 41 compiler->EmitMegamorphicInstanceCall(ic_data_, argument_count_, deopt_id_,
43 token_pos_, locs_, try_index_); 42 token_pos_, locs_, try_index_);
44 __ jmp(exit_label()); 43 __ jmp(exit_label());
(...skipping 1093 matching lines...) Expand 10 before | Expand all | Expand 10 after
1138 } 1137 }
1139 } 1138 }
1140 } 1139 }
1141 1140
1142 ASSERT(!block_order().is_empty()); 1141 ASSERT(!block_order().is_empty());
1143 VisitBlocks(); 1142 VisitBlocks();
1144 1143
1145 __ int3(); 1144 __ int3();
1146 GenerateDeferredCode(); 1145 GenerateDeferredCode();
1147 1146
1148 if (is_optimizing() && !FLAG_precompilation) { 1147 if (is_optimizing() && !FLAG_precompiled_mode) {
1149 // Leave enough space for patching in case of lazy deoptimization from 1148 // Leave enough space for patching in case of lazy deoptimization from
1150 // deferred code. 1149 // deferred code.
1151 __ nop(CallPattern::pattern_length_in_bytes()); 1150 __ nop(CallPattern::pattern_length_in_bytes());
1152 lazy_deopt_pc_offset_ = assembler()->CodeSize(); 1151 lazy_deopt_pc_offset_ = assembler()->CodeSize();
1153 __ Jmp(*StubCode::DeoptimizeLazy_entry()); 1152 __ Jmp(*StubCode::DeoptimizeLazy_entry());
1154 } 1153 }
1155 } 1154 }
1156 1155
1157 1156
1158 void FlowGraphCompiler::GenerateCall(TokenPosition token_pos, 1157 void FlowGraphCompiler::GenerateCall(TokenPosition token_pos,
(...skipping 145 matching lines...) Expand 10 before | Expand all | Expand 10 after
1304 } else { 1303 } else {
1305 StubCode::EmitMegamorphicLookup(assembler()); 1304 StubCode::EmitMegamorphicLookup(assembler());
1306 } 1305 }
1307 __ call(EBX); 1306 __ call(EBX);
1308 1307
1309 AddCurrentDescriptor(RawPcDescriptors::kOther, 1308 AddCurrentDescriptor(RawPcDescriptors::kOther,
1310 Thread::kNoDeoptId, token_pos); 1309 Thread::kNoDeoptId, token_pos);
1311 RecordSafepoint(locs); 1310 RecordSafepoint(locs);
1312 const intptr_t deopt_id_after = Thread::ToDeoptAfter(deopt_id); 1311 const intptr_t deopt_id_after = Thread::ToDeoptAfter(deopt_id);
1313 // Precompilation not implemented on ia32 platform. 1312 // Precompilation not implemented on ia32 platform.
1314 ASSERT(!FLAG_precompilation); 1313 ASSERT(!FLAG_precompiled_mode);
1315 if (is_optimizing()) { 1314 if (is_optimizing()) {
1316 AddDeoptIndexAtCall(deopt_id_after, token_pos); 1315 AddDeoptIndexAtCall(deopt_id_after, token_pos);
1317 } else { 1316 } else {
1318 // Add deoptimization continuation point after the call and before the 1317 // Add deoptimization continuation point after the call and before the
1319 // arguments are removed. 1318 // arguments are removed.
1320 AddCurrentDescriptor(RawPcDescriptors::kDeopt, deopt_id_after, token_pos); 1319 AddCurrentDescriptor(RawPcDescriptors::kDeopt, deopt_id_after, token_pos);
1321 } 1320 }
1322 __ Drop(argument_count); 1321 __ Drop(argument_count);
1323 } 1322 }
1324 1323
(...skipping 522 matching lines...) Expand 10 before | Expand all | Expand 10 after
1847 __ movups(reg, Address(ESP, 0)); 1846 __ movups(reg, Address(ESP, 0));
1848 __ addl(ESP, Immediate(kFpuRegisterSize)); 1847 __ addl(ESP, Immediate(kFpuRegisterSize));
1849 } 1848 }
1850 1849
1851 1850
1852 #undef __ 1851 #undef __
1853 1852
1854 } // namespace dart 1853 } // namespace dart
1855 1854
1856 #endif // defined TARGET_ARCH_IA32 1855 #endif // defined TARGET_ARCH_IA32
OLDNEW
« no previous file with comments | « runtime/vm/flow_graph_compiler_arm64.cc ('k') | runtime/vm/flow_graph_compiler_mips.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698