| OLD | NEW |
| 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 #ifndef VM_FLAG_LIST_H_ | 5 #ifndef VM_FLAG_LIST_H_ |
| 6 #define VM_FLAG_LIST_H_ | 6 #define VM_FLAG_LIST_H_ |
| 7 | 7 |
| 8 // List of all flags in the VM. | 8 // List of all flags in the VM. |
| 9 // Flags can be one of three categories: | 9 // Flags can be one of three categories: |
| 10 // * P roduct flags: Can be set in any of the deployment modes, including in | 10 // * P roduct flags: Can be set in any of the deployment modes, including in |
| 11 // production. | 11 // production. |
| 12 // * D ebug flags: Can only be set in debug VMs, which also have assertions | 12 // * D ebug flags: Can only be set in debug VMs, which also have assertions |
| 13 // enabled. | 13 // enabled. |
| 14 // * R elease flags: Generally available flags except when building product. | 14 // * R elease flags: Generally available flags except when building product. |
| 15 // * pre C ompile flags: Generally available flags except when building product | 15 // * pre C ompile flags: Generally available flags except when building product |
| 16 // or precompiled runtime. | 16 // or precompiled runtime. |
| 17 // | 17 // |
| 18 // Usage: | 18 // Usage: |
| 19 // P(name, type, default_value, comment) | 19 // P(name, type, default_value, comment) |
| 20 // D(name, type, default_value, comment) | 20 // D(name, type, default_value, comment) |
| 21 // R(name, product_value, type, default_value, comment) | 21 // R(name, product_value, type, default_value, comment) |
| 22 // C(name, precompiled_value, product_value, type, default_value, comment) | 22 // C(name, precompiled_value, product_value, type, default_value, comment) |
| 23 #define FLAG_LIST(P, R, D, C) \ | 23 #define FLAG_LIST(P, R, D, C) \ |
| 24 C(allow_absolute_addresses, false, true, bool, true, \ |
| 25 "Allow embedding absolute addresses in generated code.") \ |
| 26 C(always_megamorphic_calls, true, false, bool, false, \ |
| 27 "Instance call always as megamorphic.") \ |
| 28 C(background_compilation, false, false, bool, false, \ |
| 29 "Run optimizing compilation in background") \ |
| 30 C(collect_code, false, true, bool, true, \ |
| 31 "Attempt to GC infrequently used code.") \ |
| 32 C(collect_dynamic_function_names, true, false, bool, false, \ |
| 33 "Collects all dynamic function names to identify unique targets") \ |
| 24 R(dedup_instructions, true, bool, false, \ | 34 R(dedup_instructions, true, bool, false, \ |
| 25 "Canonicalize instructions when precompiling.") \ | 35 "Canonicalize instructions when precompiling.") \ |
| 36 C(deoptimize_alot, false, false, bool, false, \ |
| 37 "Deoptimizes we are about to return to Dart code from native entries.") \ |
| 38 C(deoptimize_every, 0, 0, int, 0, \ |
| 39 "Deoptimize on every N stack overflow checks") \ |
| 26 R(disable_alloc_stubs_after_gc, false, bool, false, \ | 40 R(disable_alloc_stubs_after_gc, false, bool, false, \ |
| 27 "Stress testing flag.") \ | 41 "Stress testing flag.") \ |
| 28 R(disassemble, false, bool, false, \ | 42 R(disassemble, false, bool, false, \ |
| 29 "Disassemble dart code.") \ | 43 "Disassemble dart code.") \ |
| 30 R(disassemble_optimized, false, bool, false, \ | 44 R(disassemble_optimized, false, bool, false, \ |
| 31 "Disassemble optimized code.") \ | 45 "Disassemble optimized code.") \ |
| 32 R(dump_symbol_stats, false, bool, false, \ | 46 R(dump_symbol_stats, false, bool, false, \ |
| 33 "Dump symbol table statistics") \ | 47 "Dump symbol table statistics") \ |
| 34 R(enable_mirrors, false, bool, true, \ | 48 C(emit_edge_counters, false, true, bool, true, \ |
| 49 "Emit edge counters") \ |
| 50 C(enable_mirrors, false, false, bool, true, \ |
| 35 "Disable to make importing dart:mirrors an error.") \ | 51 "Disable to make importing dart:mirrors an error.") \ |
| 52 C(fields_may_be_reset, true, false, bool, false, \ |
| 53 "Don't optimize away static field initialization") \ |
| 36 R(gc_at_alloc, false, bool, false, \ | 54 R(gc_at_alloc, false, bool, false, \ |
| 37 "GC at every allocation.") \ | 55 "GC at every allocation.") \ |
| 38 P(getter_setter_ratio, int, 13, \ | 56 P(getter_setter_ratio, int, 13, \ |
| 39 "Ratio of getter/setter usage used for double field unboxing heuristics") \ | 57 "Ratio of getter/setter usage used for double field unboxing heuristics") \ |
| 40 P(guess_icdata_cid, bool, true, \ | 58 P(guess_icdata_cid, bool, true, \ |
| 41 "Artificially create type feedback for arithmetic etc. operations") \ | 59 "Artificially create type feedback for arithmetic etc. operations") \ |
| 60 C(ic_range_profiling, false, true, bool, true, \ |
| 61 "Generate special IC stubs collecting range information ") \ |
| 62 C(interpret_irregexp, true, false, bool, false, \ |
| 63 "Use irregexp bytecode interpreter") \ |
| 42 C(lazy_dispatchers, false, true, bool, true, \ | 64 C(lazy_dispatchers, false, true, bool, true, \ |
| 43 "Generate dispatchers lazily") \ | 65 "Generate dispatchers lazily") \ |
| 66 C(link_natives_lazily, true, false, bool, false, \ |
| 67 "Link native calls lazily") \ |
| 68 C(load_deferred_eagerly, true, true, bool, false, \ |
| 69 "Load deferred libraries eagerly.") \ |
| 44 P(max_polymorphic_checks, int, 4, \ | 70 P(max_polymorphic_checks, int, 4, \ |
| 45 "Maximum number of polymorphic check, otherwise it is megamorphic.") \ | 71 "Maximum number of polymorphic check, otherwise it is megamorphic.") \ |
| 46 P(max_equality_polymorphic_checks, int, 32, \ | 72 P(max_equality_polymorphic_checks, int, 32, \ |
| 47 "Maximum number of polymorphic checks in equality operator,") \ | 73 "Maximum number of polymorphic checks in equality operator,") \ |
| 48 P(merge_sin_cos, bool, false, \ | 74 P(merge_sin_cos, bool, false, \ |
| 49 "Merge sin/cos into sincos") \ | 75 "Merge sin/cos into sincos") \ |
| 50 P(new_gen_ext_limit, int, 64, \ | 76 P(new_gen_ext_limit, int, 64, \ |
| 51 "maximum total external size (MB) in new gen before triggering GC") \ | 77 "maximum total external size (MB) in new gen before triggering GC") \ |
| 78 C(optimization_counter_threshold, -1, 30000, int, 30000, \ |
| 79 "Function's usage-counter value before it is optimized, -1 means never") \ |
| 52 C(polymorphic_with_deopt, false, true, bool, true, \ | 80 C(polymorphic_with_deopt, false, true, bool, true, \ |
| 53 "Polymorphic calls with deoptimization / megamorphic call") \ | 81 "Polymorphic calls with deoptimization / megamorphic call") \ |
| 82 C(precompiled_mode, true, false, bool, false, \ |
| 83 "Precompilation compiler/runtime mode") \ |
| 54 R(pretenure_all, false, bool, false, \ | 84 R(pretenure_all, false, bool, false, \ |
| 55 "Global pretenuring (for testing).") \ | 85 "Global pretenuring (for testing).") \ |
| 56 P(pretenure_interval, int, 10, \ | 86 P(pretenure_interval, int, 10, \ |
| 57 "Back off pretenuring after this many cycles.") \ | 87 "Back off pretenuring after this many cycles.") \ |
| 58 P(pretenure_threshold, int, 98, \ | 88 P(pretenure_threshold, int, 98, \ |
| 59 "Trigger pretenuring when this many percent are promoted.") \ | 89 "Trigger pretenuring when this many percent are promoted.") \ |
| 90 C(print_stop_message, false, false, bool, false, \ |
| 91 "Print stop message.") \ |
| 60 R(profiler, false, bool, true, \ | 92 R(profiler, false, bool, true, \ |
| 61 "Enable the profiler.") \ | 93 "Enable the profiler.") \ |
| 62 R(support_ast_printer, false, bool, true, \ | 94 R(support_ast_printer, false, bool, true, \ |
| 63 "Support the AST printer.") \ | 95 "Support the AST printer.") \ |
| 64 R(support_compiler_stats, false, bool, true, \ | 96 R(support_compiler_stats, false, bool, true, \ |
| 65 "Support compiler stats.") \ | 97 "Support compiler stats.") \ |
| 66 R(support_debugger, false, bool, true, \ | 98 R(support_debugger, false, bool, true, \ |
| 67 "Support the debugger.") \ | 99 "Support the debugger.") \ |
| 68 R(support_disassembler, false, bool, true, \ | 100 R(support_disassembler, false, bool, true, \ |
| 69 "Support the disassembler.") \ | 101 "Support the disassembler.") \ |
| (...skipping 12 matching lines...) Expand all Loading... |
| 82 D(trace_handles, bool, false, \ | 114 D(trace_handles, bool, false, \ |
| 83 "Traces allocation of handles.") \ | 115 "Traces allocation of handles.") \ |
| 84 D(trace_optimization, bool, false, \ | 116 D(trace_optimization, bool, false, \ |
| 85 "Print optimization details."); \ | 117 "Print optimization details."); \ |
| 86 D(trace_zones, bool, false, \ | 118 D(trace_zones, bool, false, \ |
| 87 "Traces allocation sizes in the zone.") \ | 119 "Traces allocation sizes in the zone.") \ |
| 88 P(truncating_left_shift, bool, true, \ | 120 P(truncating_left_shift, bool, true, \ |
| 89 "Optimize left shift to truncate if possible") \ | 121 "Optimize left shift to truncate if possible") \ |
| 90 C(use_cha_deopt, false, true, bool, true, \ | 122 C(use_cha_deopt, false, true, bool, true, \ |
| 91 "Use class hierarchy analysis even if it can cause deoptimization.") \ | 123 "Use class hierarchy analysis even if it can cause deoptimization.") \ |
| 124 C(use_field_guards, false, true, bool, true, \ |
| 125 "Use field guards and track field types") \ |
| 126 C(use_osr, false, true, bool, true, \ |
| 127 "Use OSR") \ |
| 92 P(verbose_gc, bool, false, \ | 128 P(verbose_gc, bool, false, \ |
| 93 "Enables verbose GC.") \ | 129 "Enables verbose GC.") \ |
| 94 P(verbose_gc_hdr, int, 40, \ | 130 P(verbose_gc_hdr, int, 40, \ |
| 95 "Print verbose GC header interval.") \ | 131 "Print verbose GC header interval.") \ |
| 96 R(verify_after_gc, false, bool, false, \ | 132 R(verify_after_gc, false, bool, false, \ |
| 97 "Enables heap verification after GC.") \ | 133 "Enables heap verification after GC.") \ |
| 98 R(verify_before_gc, false, bool, false, \ | 134 R(verify_before_gc, false, bool, false, \ |
| 99 "Enables heap verification before GC.") \ | 135 "Enables heap verification before GC.") \ |
| 100 | 136 |
| 101 | |
| 102 #endif // VM_FLAG_LIST_H_ | 137 #endif // VM_FLAG_LIST_H_ |
| OLD | NEW |