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

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

Issue 2976723003: Eliminate dependencies on assemblers and code stubs in precompiled runtime. (Closed)
Patch Set: Eliminate precompiled runtime flag Created 3 years, 5 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/cha.cc ('k') | runtime/vm/constant_propagator.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) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, 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/compiler.h" 5 #include "vm/compiler.h"
6 6
7 #include "vm/assembler.h" 7 #include "vm/assembler.h"
8 8
9 #include "vm/ast_printer.h" 9 #include "vm/ast_printer.h"
10 #include "vm/block_scheduler.h" 10 #include "vm/block_scheduler.h"
(...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after
100 "Trace only optimizing compiler operations."); 100 "Trace only optimizing compiler operations.");
101 DEFINE_FLAG(bool, trace_bailout, false, "Print bailout from ssa compiler."); 101 DEFINE_FLAG(bool, trace_bailout, false, "Print bailout from ssa compiler.");
102 DEFINE_FLAG(bool, use_inlining, true, "Enable call-site inlining"); 102 DEFINE_FLAG(bool, use_inlining, true, "Enable call-site inlining");
103 DEFINE_FLAG(bool, 103 DEFINE_FLAG(bool,
104 verify_compiler, 104 verify_compiler,
105 false, 105 false,
106 "Enable compiler verification assertions"); 106 "Enable compiler verification assertions");
107 107
108 DECLARE_FLAG(bool, huge_method_cutoff_in_code_size); 108 DECLARE_FLAG(bool, huge_method_cutoff_in_code_size);
109 DECLARE_FLAG(bool, trace_failed_optimization_attempts); 109 DECLARE_FLAG(bool, trace_failed_optimization_attempts);
110 DECLARE_FLAG(bool, unbox_numeric_fields);
111
112
113 static void PrecompilationModeHandler(bool value) {
114 if (value) {
115 #if defined(TARGET_ARCH_IA32)
116 FATAL("Precompilation not supported on IA32");
117 #endif
118
119 FLAG_background_compilation = false;
120 FLAG_fields_may_be_reset = true;
121 FLAG_interpret_irregexp = true;
122 FLAG_lazy_dispatchers = false;
123 FLAG_link_natives_lazily = true;
124 FLAG_optimization_counter_threshold = -1;
125 FLAG_polymorphic_with_deopt = false;
126 FLAG_precompiled_mode = true;
127 FLAG_reorder_basic_blocks = false;
128 FLAG_use_field_guards = false;
129 FLAG_use_cha_deopt = false;
130
131 #if !defined(PRODUCT) && !defined(DART_PRECOMPILED_RUNTIME)
132 // Set flags affecting runtime accordingly for dart_bootstrap.
133 // These flags are constants with PRODUCT and DART_PRECOMPILED_RUNTIME.
134 FLAG_collect_code = false;
135 FLAG_support_debugger = false;
136 FLAG_deoptimize_alot = false; // Used in some tests.
137 FLAG_deoptimize_every = 0; // Used in some tests.
138 FLAG_enable_mirrors = false;
139 FLAG_load_deferred_eagerly = true;
140 FLAG_print_stop_message = false;
141 FLAG_unbox_numeric_fields = false;
142 FLAG_use_osr = false;
143 #endif
144 }
145 }
146
147 DEFINE_FLAG_HANDLER(PrecompilationModeHandler,
148 precompilation,
149 "Precompilation mode");
110 150
111 151
112 #ifndef DART_PRECOMPILED_RUNTIME 152 #ifndef DART_PRECOMPILED_RUNTIME
113 153
114 154
115 bool UseKernelFrontEndFor(ParsedFunction* parsed_function) { 155 bool UseKernelFrontEndFor(ParsedFunction* parsed_function) {
116 const Function& function = parsed_function->function(); 156 const Function& function = parsed_function->function();
117 return (function.kernel_offset() > 0) || 157 return (function.kernel_offset() > 0) ||
118 (function.kind() == RawFunction::kNoSuchMethodDispatcher) || 158 (function.kind() == RawFunction::kNoSuchMethodDispatcher) ||
119 (function.kind() == RawFunction::kInvokeFieldDispatcher); 159 (function.kind() == RawFunction::kInvokeFieldDispatcher);
(...skipping 2236 matching lines...) Expand 10 before | Expand all | Expand 10 after
2356 2396
2357 2397
2358 bool BackgroundCompiler::IsDisabled() { 2398 bool BackgroundCompiler::IsDisabled() {
2359 UNREACHABLE(); 2399 UNREACHABLE();
2360 return true; 2400 return true;
2361 } 2401 }
2362 2402
2363 #endif // DART_PRECOMPILED_RUNTIME 2403 #endif // DART_PRECOMPILED_RUNTIME
2364 2404
2365 } // namespace dart 2405 } // namespace dart
OLDNEW
« no previous file with comments | « runtime/vm/cha.cc ('k') | runtime/vm/constant_propagator.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698