LCOV - code coverage report
Current view: top level - src - flag-definitions.h (source / functions) Hit Total Coverage
Test: app.info Lines: 58 59 98.3 %
Date: 2017-04-26 Functions: 0 0 -

          Line data    Source code
       1             : // Copyright 2012 the V8 project authors. All rights reserved.
       2             : // Use of this source code is governed by a BSD-style license that can be
       3             : // found in the LICENSE file.
       4             : 
       5             : // This file defines all of the flags.  It is separated into different section,
       6             : // for Debug, Release, Logging and Profiling, etc.  To add a new flag, find the
       7             : // correct section, and use one of the DEFINE_ macros, without a trailing ';'.
       8             : //
       9             : // This include does not have a guard, because it is a template-style include,
      10             : // which can be included multiple times in different modes.  It expects to have
      11             : // a mode defined before it's included.  The modes are FLAG_MODE_... below:
      12             : 
      13             : #define DEFINE_IMPLICATION(whenflag, thenflag)              \
      14             :   DEFINE_VALUE_IMPLICATION(whenflag, thenflag, true)
      15             : 
      16             : #define DEFINE_NEG_IMPLICATION(whenflag, thenflag)          \
      17             :   DEFINE_VALUE_IMPLICATION(whenflag, thenflag, false)
      18             : 
      19             : #define DEFINE_NEG_NEG_IMPLICATION(whenflag, thenflag) \
      20             :   DEFINE_NEG_VALUE_IMPLICATION(whenflag, thenflag, false)
      21             : 
      22             : #define DEFINE_DUAL_IMPLICATION(whenflag, thenflag) \
      23             :   DEFINE_IMPLICATION(whenflag, thenflag)            \
      24             :   DEFINE_NEG_NEG_IMPLICATION(whenflag, thenflag)
      25             : 
      26             : // We want to declare the names of the variables for the header file.  Normally
      27             : // this will just be an extern declaration, but for a readonly flag we let the
      28             : // compiler make better optimizations by giving it the value.
      29             : #if defined(FLAG_MODE_DECLARE)
      30             : #define FLAG_FULL(ftype, ctype, nam, def, cmt) \
      31             :   V8_EXPORT_PRIVATE extern ctype FLAG_##nam;
      32             : #define FLAG_READONLY(ftype, ctype, nam, def, cmt) \
      33             :   static ctype const FLAG_##nam = def;
      34             : 
      35             : // We want to supply the actual storage and value for the flag variable in the
      36             : // .cc file.  We only do this for writable flags.
      37             : #elif defined(FLAG_MODE_DEFINE)
      38             : #ifdef USING_V8_SHARED
      39             : #define FLAG_FULL(ftype, ctype, nam, def, cmt) \
      40             :   V8_EXPORT_PRIVATE extern ctype FLAG_##nam;
      41             : #else
      42             : #define FLAG_FULL(ftype, ctype, nam, def, cmt) \
      43             :   V8_EXPORT_PRIVATE ctype FLAG_##nam = def;
      44             : #endif
      45             : 
      46             : // We need to define all of our default values so that the Flag structure can
      47             : // access them by pointer.  These are just used internally inside of one .cc,
      48             : // for MODE_META, so there is no impact on the flags interface.
      49             : #elif defined(FLAG_MODE_DEFINE_DEFAULTS)
      50             : #define FLAG_FULL(ftype, ctype, nam, def, cmt) \
      51             :   static ctype const FLAGDEFAULT_##nam = def;
      52             : 
      53             : // We want to write entries into our meta data table, for internal parsing and
      54             : // printing / etc in the flag parser code.  We only do this for writable flags.
      55             : #elif defined(FLAG_MODE_META)
      56             : #define FLAG_FULL(ftype, ctype, nam, def, cmt)                              \
      57             :   { Flag::TYPE_##ftype, #nam, &FLAG_##nam, &FLAGDEFAULT_##nam, cmt, false } \
      58             :   ,
      59             : #define FLAG_ALIAS(ftype, ctype, alias, nam)                     \
      60             :   {                                                              \
      61             :     Flag::TYPE_##ftype, #alias, &FLAG_##nam, &FLAGDEFAULT_##nam, \
      62             :         "alias for --" #nam, false                               \
      63             :   }                                                              \
      64             :   ,
      65             : 
      66             : // We produce the code to set flags when it is implied by another flag.
      67             : #elif defined(FLAG_MODE_DEFINE_IMPLICATIONS)
      68             : #define DEFINE_VALUE_IMPLICATION(whenflag, thenflag, value) \
      69             :   if (FLAG_##whenflag) FLAG_##thenflag = value;
      70             : 
      71             : #define DEFINE_NEG_VALUE_IMPLICATION(whenflag, thenflag, value) \
      72             :   if (!FLAG_##whenflag) FLAG_##thenflag = value;
      73             : 
      74             : #else
      75             : #error No mode supplied when including flags.defs
      76             : #endif
      77             : 
      78             : // Dummy defines for modes where it is not relevant.
      79             : #ifndef FLAG_FULL
      80             : #define FLAG_FULL(ftype, ctype, nam, def, cmt)
      81             : #endif
      82             : 
      83             : #ifndef FLAG_READONLY
      84             : #define FLAG_READONLY(ftype, ctype, nam, def, cmt)
      85             : #endif
      86             : 
      87             : #ifndef FLAG_ALIAS
      88             : #define FLAG_ALIAS(ftype, ctype, alias, nam)
      89             : #endif
      90             : 
      91             : #ifndef DEFINE_VALUE_IMPLICATION
      92             : #define DEFINE_VALUE_IMPLICATION(whenflag, thenflag, value)
      93             : #endif
      94             : 
      95             : #ifndef DEFINE_NEG_VALUE_IMPLICATION
      96             : #define DEFINE_NEG_VALUE_IMPLICATION(whenflag, thenflag, value)
      97             : #endif
      98             : 
      99             : #define COMMA ,
     100             : 
     101             : #ifdef FLAG_MODE_DECLARE
     102             : // Structure used to hold a collection of arguments to the JavaScript code.
     103             : struct JSArguments {
     104             :  public:
     105           0 :   inline const char*& operator[](int idx) const { return argv[idx]; }
     106             :   static JSArguments Create(int argc, const char** argv) {
     107             :     JSArguments args;
     108             :     args.argc = argc;
     109             :     args.argv = argv;
     110             :     return args;
     111             :   }
     112             :   int argc;
     113             :   const char** argv;
     114             : };
     115             : 
     116             : struct MaybeBoolFlag {
     117             :   static MaybeBoolFlag Create(bool has_value, bool value) {
     118             :     MaybeBoolFlag flag;
     119             :     flag.has_value = has_value;
     120          34 :     flag.value = value;
     121             :     return flag;
     122             :   }
     123             :   bool has_value;
     124             :   bool value;
     125             : };
     126             : #endif
     127             : 
     128             : #ifdef DEBUG
     129             : #define DEBUG_BOOL true
     130             : #else
     131             : #define DEBUG_BOOL false
     132             : #endif
     133             : 
     134             : // Supported ARM configurations are:
     135             : //  "armv6":       ARMv6 + VFPv2
     136             : //  "armv7":       ARMv7 + VFPv3-D32 + NEON
     137             : //  "armv7+sudiv": ARMv7 + VFPv4-D32 + NEON + SUDIV
     138             : //  "armv8":       ARMv8 (including all of the above)
     139             : #if !defined(ARM_TEST_NO_FEATURE_PROBE) ||                            \
     140             :     (defined(CAN_USE_ARMV8_INSTRUCTIONS) &&                           \
     141             :      defined(CAN_USE_ARMV7_INSTRUCTIONS) && defined(CAN_USE_SUDIV) && \
     142             :      defined(CAN_USE_NEON) && defined(CAN_USE_VFP3_INSTRUCTIONS))
     143             : #define ARM_ARCH_DEFAULT "armv8"
     144             : #elif defined(CAN_USE_ARMV7_INSTRUCTIONS) && defined(CAN_USE_SUDIV) && \
     145             :     defined(CAN_USE_NEON) && defined(CAN_USE_VFP3_INSTRUCTIONS)
     146             : #define ARM_ARCH_DEFAULT "armv7+sudiv"
     147             : #elif defined(CAN_USE_ARMV7_INSTRUCTIONS) && defined(CAN_USE_NEON) && \
     148             :     defined(CAN_USE_VFP3_INSTRUCTIONS)
     149             : #define ARM_ARCH_DEFAULT "armv7"
     150             : #else
     151             : #define ARM_ARCH_DEFAULT "armv6"
     152             : #endif
     153             : 
     154             : #ifdef V8_OS_WIN
     155             : # define ENABLE_LOG_COLOUR false
     156             : #else
     157             : # define ENABLE_LOG_COLOUR true
     158             : #endif
     159             : 
     160             : #define DEFINE_BOOL(nam, def, cmt) FLAG(BOOL, bool, nam, def, cmt)
     161             : #define DEFINE_BOOL_READONLY(nam, def, cmt) \
     162             :   FLAG_READONLY(BOOL, bool, nam, def, cmt)
     163             : #define DEFINE_MAYBE_BOOL(nam, cmt) \
     164             :   FLAG(MAYBE_BOOL, MaybeBoolFlag, nam, {false COMMA false}, cmt)
     165             : #define DEFINE_INT(nam, def, cmt) FLAG(INT, int, nam, def, cmt)
     166             : #define DEFINE_UINT(nam, def, cmt) FLAG(UINT, unsigned int, nam, def, cmt)
     167             : #define DEFINE_FLOAT(nam, def, cmt) FLAG(FLOAT, double, nam, def, cmt)
     168             : #define DEFINE_STRING(nam, def, cmt) FLAG(STRING, const char*, nam, def, cmt)
     169             : #define DEFINE_ARGS(nam, cmt) FLAG(ARGS, JSArguments, nam, {0 COMMA NULL}, cmt)
     170             : 
     171             : #define DEFINE_ALIAS_BOOL(alias, nam) FLAG_ALIAS(BOOL, bool, alias, nam)
     172             : #define DEFINE_ALIAS_INT(alias, nam) FLAG_ALIAS(INT, int, alias, nam)
     173             : #define DEFINE_ALIAS_FLOAT(alias, nam) FLAG_ALIAS(FLOAT, double, alias, nam)
     174             : #define DEFINE_ALIAS_STRING(alias, nam) \
     175             :   FLAG_ALIAS(STRING, const char*, alias, nam)
     176             : #define DEFINE_ALIAS_ARGS(alias, nam) FLAG_ALIAS(ARGS, JSArguments, alias, nam)
     177             : 
     178             : //
     179             : // Flags in all modes.
     180             : //
     181             : #define FLAG FLAG_FULL
     182             : 
     183             : DEFINE_BOOL(experimental_extras, false,
     184             :             "enable code compiled in via v8_experimental_extra_library_files")
     185             : 
     186             : // Flags for language modes and experimental language features.
     187             : DEFINE_BOOL(use_strict, false, "enforce strict mode")
     188             : 
     189             : DEFINE_BOOL(es_staging, false,
     190             :             "enable test-worthy harmony features (for internal use only)")
     191             : DEFINE_BOOL(harmony, false, "enable all completed harmony features")
     192             : DEFINE_BOOL(harmony_shipping, true, "enable all shipped harmony features")
     193      206204 : DEFINE_IMPLICATION(es_staging, harmony)
     194             : 
     195             : // Features that are still work in progress (behind individual flags).
     196             : #define HARMONY_INPROGRESS(V)                                           \
     197             :   V(harmony_array_prototype_values, "harmony Array.prototype.values")   \
     198             :   V(harmony_function_sent, "harmony function.sent")                     \
     199             :   V(harmony_tailcalls, "harmony tail calls")                            \
     200             :   V(harmony_sharedarraybuffer, "harmony sharedarraybuffer")             \
     201             :   V(harmony_do_expressions, "harmony do-expressions")                   \
     202             :   V(harmony_class_fields, "harmony public fields in class literals")    \
     203             :   V(harmony_async_iteration, "harmony async iteration")                 \
     204             :   V(harmony_dynamic_import, "harmony dynamic import")                   \
     205             :   V(harmony_promise_finally, "harmony Promise.prototype.finally")       \
     206             :   V(harmony_restrict_constructor_return,                                \
     207             :     "harmony disallow non undefined primitive return value from class " \
     208             :     "constructor")
     209             : 
     210             : // Features that are complete (but still behind --harmony/es-staging flag).
     211             : #define HARMONY_STAGED(V)                                               \
     212             :   V(harmony_function_tostring, "harmony Function.prototype.toString")   \
     213             :   V(harmony_regexp_dotall, "harmony regexp dotall flag")                \
     214             :   V(harmony_regexp_lookbehind, "harmony regexp lookbehind")             \
     215             :   V(harmony_regexp_named_captures, "harmony regexp named captures")     \
     216             :   V(harmony_regexp_property, "harmony unicode regexp property classes") \
     217             :   V(harmony_strict_legacy_accessor_builtins,                            \
     218             :     "treat __defineGetter__ and related functions as strict")           \
     219             :   V(harmony_template_escapes,                                           \
     220             :     "harmony invalid escapes in tagged template literals")
     221             : 
     222             : // Features that are shipping (turned on by default, but internal flag remains).
     223             : #define HARMONY_SHIPPING_BASE(V)                           \
     224             :   V(harmony_restrictive_generators,                        \
     225             :     "harmony restrictions on generator declarations")      \
     226             :   V(harmony_trailing_commas,                               \
     227             :     "harmony trailing commas in function parameter lists") \
     228             :   V(harmony_object_rest_spread, "harmony object rest spread properties")
     229             : 
     230             : #ifdef V8_INTL_SUPPORT
     231             : #define HARMONY_SHIPPING(V)                                        \
     232             :   HARMONY_SHIPPING_BASE(V)                                         \
     233             :   V(icu_case_mapping, "case mapping with ICU rather than Unibrow")
     234             : #else
     235             : #define HARMONY_SHIPPING(V) HARMONY_SHIPPING_BASE(V)
     236             : #endif
     237             : 
     238             : // Once a shipping feature has proved stable in the wild, it will be dropped
     239             : // from HARMONY_SHIPPING, all occurrences of the FLAG_ variable are removed,
     240             : // and associated tests are moved from the harmony directory to the appropriate
     241             : // esN directory.
     242             : 
     243             : 
     244             : #define FLAG_INPROGRESS_FEATURES(id, description) \
     245             :   DEFINE_BOOL(id, false, "enable " #description " (in progress)")
     246             : HARMONY_INPROGRESS(FLAG_INPROGRESS_FEATURES)
     247             : #undef FLAG_INPROGRESS_FEATURES
     248             : 
     249             : #define FLAG_STAGED_FEATURES(id, description) \
     250             :   DEFINE_BOOL(id, false, "enable " #description) \
     251             :   DEFINE_IMPLICATION(harmony, id)
     252      206204 : HARMONY_STAGED(FLAG_STAGED_FEATURES)
     253             : #undef FLAG_STAGED_FEATURES
     254             : 
     255             : #define FLAG_SHIPPING_FEATURES(id, description) \
     256             :   DEFINE_BOOL(id, true, "enable " #description) \
     257             :   DEFINE_NEG_NEG_IMPLICATION(harmony_shipping, id)
     258      206204 : HARMONY_SHIPPING(FLAG_SHIPPING_FEATURES)
     259             : #undef FLAG_SHIPPING_FEATURES
     260             : 
     261             : #ifdef V8_INTL_SUPPORT
     262             : DEFINE_BOOL(icu_timezone_data, false,
     263             :             "get information about timezones from ICU")
     264             : #endif
     265             : 
     266             : #ifdef V8_ENABLE_FUTURE
     267             : #define FUTURE_BOOL true
     268             : #else
     269             : #define FUTURE_BOOL false
     270             : #endif
     271             : DEFINE_BOOL(future, FUTURE_BOOL,
     272             :             "Implies all staged features that we want to ship in the "
     273             :             "not-too-far future")
     274      206204 : DEFINE_IMPLICATION(future, turbo)
     275             : 
     276      206204 : DEFINE_DUAL_IMPLICATION(turbo, ignition)
     277      206204 : DEFINE_DUAL_IMPLICATION(turbo, thin_strings)
     278             : 
     279             : // Flags for experimental implementation features.
     280             : DEFINE_BOOL(allocation_site_pretenuring, true,
     281             :             "pretenure with allocation sites")
     282             : DEFINE_BOOL(mark_shared_functions_for_tier_up, true,
     283             :             "mark shared functions for tier up")
     284             : DEFINE_BOOL(mark_optimizing_shared_functions, true,
     285             :             "mark shared functions if they are concurrently optimizing")
     286             : DEFINE_BOOL(page_promotion, true, "promote pages based on utilization")
     287             : DEFINE_INT(page_promotion_threshold, 70,
     288             :            "min percentage of live bytes on a page to enable fast evacuation")
     289             : DEFINE_BOOL(smi_binop, true, "support smi representation in binary operations")
     290             : DEFINE_BOOL(trace_pretenuring, false,
     291             :             "trace pretenuring decisions of HAllocate instructions")
     292             : DEFINE_BOOL(trace_pretenuring_statistics, false,
     293             :             "trace allocation site pretenuring statistics")
     294             : DEFINE_BOOL(track_fields, true, "track fields with only smi values")
     295             : DEFINE_BOOL(track_double_fields, true, "track fields with double values")
     296             : DEFINE_BOOL(track_heap_object_fields, true, "track fields with heap values")
     297             : DEFINE_BOOL(track_computed_fields, true, "track computed boilerplate fields")
     298      206204 : DEFINE_IMPLICATION(track_double_fields, track_fields)
     299      206204 : DEFINE_IMPLICATION(track_heap_object_fields, track_fields)
     300      206204 : DEFINE_IMPLICATION(track_computed_fields, track_fields)
     301             : DEFINE_BOOL(track_field_types, true, "track field types")
     302      206204 : DEFINE_IMPLICATION(track_field_types, track_fields)
     303      206204 : DEFINE_IMPLICATION(track_field_types, track_heap_object_fields)
     304             : DEFINE_BOOL(type_profile, false, "collect type information")
     305             : DEFINE_BOOL(feedback_normalization, false,
     306             :             "feed back normalization to constructors")
     307             : // TODO(jkummerow): This currently adds too much load on the stub cache.
     308             : DEFINE_BOOL_READONLY(internalize_on_the_fly, false,
     309             :                      "internalize string keys for generic keyed ICs on the fly")
     310             : 
     311             : // Flags for optimization types.
     312             : DEFINE_BOOL(optimize_for_size, false,
     313             :             "Enables optimizations which favor memory size over execution "
     314             :             "speed")
     315             : 
     316      206204 : DEFINE_VALUE_IMPLICATION(optimize_for_size, max_semi_space_size, 1)
     317             : 
     318             : // Flags for data representation optimizations
     319             : DEFINE_BOOL(unbox_double_arrays, true, "automatically unbox arrays of doubles")
     320             : DEFINE_BOOL(string_slices, true, "use string slices")
     321             : 
     322             : // Flags for Ignition.
     323             : DEFINE_BOOL(ignition, false, "use ignition interpreter")
     324             : DEFINE_BOOL(ignition_osr, true, "enable support for OSR from ignition code")
     325             : DEFINE_BOOL(ignition_elide_noneffectful_bytecodes, true,
     326             :             "elide bytecodes which won't have any external effect")
     327             : DEFINE_BOOL(ignition_reo, true, "use ignition register equivalence optimizer")
     328             : DEFINE_BOOL(ignition_filter_expression_positions, true,
     329             :             "filter expression positions before the bytecode pipeline")
     330             : DEFINE_BOOL(print_bytecode, false,
     331             :             "print bytecode generated by ignition interpreter")
     332             : DEFINE_STRING(print_bytecode_filter, "*",
     333             :               "filter for selecting which functions to print bytecode")
     334             : DEFINE_BOOL(trace_ignition, false,
     335             :             "trace the bytecodes executed by the ignition interpreter")
     336             : DEFINE_BOOL(trace_ignition_codegen, false,
     337             :             "trace the codegen of ignition interpreter bytecode handlers")
     338             : DEFINE_BOOL(trace_ignition_dispatches, false,
     339             :             "traces the dispatches to bytecode handlers by the ignition "
     340             :             "interpreter")
     341             : DEFINE_STRING(trace_ignition_dispatches_output_file, nullptr,
     342             :               "the file to which the bytecode handler dispatch table is "
     343             :               "written (by default, the table is not written to a file)")
     344             : 
     345             : // Flags for Crankshaft.
     346             : DEFINE_BOOL(crankshaft, true, "use crankshaft")
     347             : DEFINE_STRING(hydrogen_filter, "*", "optimization filter")
     348             : DEFINE_BOOL(use_gvn, true, "use hydrogen global value numbering")
     349             : DEFINE_INT(gvn_iterations, 3, "maximum number of GVN fix-point iterations")
     350             : DEFINE_BOOL(use_canonicalizing, true, "use hydrogen instruction canonicalizing")
     351             : DEFINE_BOOL(use_inlining, true, "use function inlining")
     352             : DEFINE_BOOL(use_escape_analysis, true, "use hydrogen escape analysis")
     353             : DEFINE_BOOL(use_allocation_folding, true, "use allocation folding")
     354             : DEFINE_BOOL(use_local_allocation_folding, false, "only fold in basic blocks")
     355             : DEFINE_BOOL(use_write_barrier_elimination, true,
     356             :             "eliminate write barriers targeting allocations in optimized code")
     357             : DEFINE_INT(max_inlining_levels, 5, "maximum number of inlining levels")
     358             : DEFINE_INT(max_inlined_source_size, 600,
     359             :            "maximum source size in bytes considered for a single inlining")
     360             : DEFINE_INT(max_inlined_nodes, 200,
     361             :            "maximum number of AST nodes considered for a single inlining")
     362             : DEFINE_INT(max_inlined_nodes_cumulative, 400,
     363             :            "maximum cumulative number of AST nodes considered for inlining")
     364             : DEFINE_BOOL(loop_invariant_code_motion, true, "loop invariant code motion")
     365             : DEFINE_BOOL(fast_math, true, "faster (but maybe less accurate) math functions")
     366             : DEFINE_BOOL(collect_megamorphic_maps_from_stub_cache, false,
     367             :             "crankshaft harvests type feedback from stub cache")
     368             : DEFINE_BOOL(hydrogen_stats, false, "print statistics for hydrogen")
     369             : DEFINE_BOOL(trace_check_elimination, false, "trace check elimination phase")
     370             : DEFINE_BOOL(trace_environment_liveness, false,
     371             :             "trace liveness of local variable slots")
     372             : DEFINE_BOOL(trace_hydrogen, false, "trace generated hydrogen to file")
     373             : DEFINE_STRING(trace_hydrogen_filter, "*", "hydrogen tracing filter")
     374             : DEFINE_BOOL(trace_hydrogen_stubs, false, "trace generated hydrogen for stubs")
     375             : DEFINE_STRING(trace_hydrogen_file, NULL, "trace hydrogen to given file name")
     376             : DEFINE_STRING(trace_phase, "HLZ", "trace generated IR for specified phases")
     377             : DEFINE_BOOL(trace_inlining, false, "trace inlining decisions")
     378             : DEFINE_BOOL(trace_load_elimination, false, "trace load elimination")
     379             : DEFINE_BOOL(trace_store_elimination, false, "trace store elimination")
     380             : DEFINE_BOOL(turbo_verify_store_elimination, false,
     381             :             "verify store elimination more rigorously")
     382             : DEFINE_BOOL(trace_alloc, false, "trace register allocator")
     383             : DEFINE_BOOL(trace_all_uses, false, "trace all use positions")
     384             : DEFINE_BOOL(trace_range, false, "trace range analysis")
     385             : DEFINE_BOOL(trace_gvn, false, "trace global value numbering")
     386             : DEFINE_BOOL(trace_representation, false, "trace representation types")
     387             : DEFINE_BOOL(trace_removable_simulates, false, "trace removable simulates")
     388             : DEFINE_BOOL(trace_escape_analysis, false, "trace hydrogen escape analysis")
     389             : DEFINE_BOOL(trace_allocation_folding, false, "trace allocation folding")
     390             : DEFINE_BOOL(trace_track_allocation_sites, false,
     391             :             "trace the tracking of allocation sites")
     392             : DEFINE_BOOL(trace_migration, false, "trace object migration")
     393             : DEFINE_BOOL(trace_generalization, false, "trace map generalization")
     394             : DEFINE_BOOL(stress_pointer_maps, false, "pointer map for every instruction")
     395             : DEFINE_BOOL(stress_environments, false, "environment for every instruction")
     396             : DEFINE_INT(deopt_every_n_times, 0,
     397             :            "deoptimize every n times a deopt point is passed")
     398             : DEFINE_INT(deopt_every_n_garbage_collections, 0,
     399             :            "deoptimize every n garbage collections")
     400             : DEFINE_BOOL(print_deopt_stress, false, "print number of possible deopt points")
     401             : DEFINE_BOOL(trap_on_deopt, false, "put a break point before deoptimizing")
     402             : DEFINE_BOOL(trap_on_stub_deopt, false,
     403             :             "put a break point before deoptimizing a stub")
     404             : DEFINE_BOOL(deoptimize_uncommon_cases, true, "deoptimize uncommon cases")
     405             : DEFINE_BOOL(polymorphic_inlining, true, "polymorphic inlining")
     406             : DEFINE_BOOL(use_osr, true, "use on-stack replacement")
     407             : DEFINE_BOOL(array_bounds_checks_elimination, true,
     408             :             "perform array bounds checks elimination")
     409             : DEFINE_BOOL(trace_bce, false, "trace array bounds check elimination")
     410             : DEFINE_BOOL(array_index_dehoisting, true, "perform array index dehoisting")
     411             : DEFINE_BOOL(analyze_environment_liveness, true,
     412             :             "analyze liveness of environment slots and zap dead values")
     413             : DEFINE_BOOL(load_elimination, true, "use load elimination")
     414             : DEFINE_BOOL(check_elimination, true, "use check elimination")
     415             : DEFINE_BOOL(store_elimination, false, "use store elimination")
     416             : DEFINE_BOOL(dead_code_elimination, true, "use dead code elimination")
     417             : DEFINE_BOOL(fold_constants, true, "use constant folding")
     418             : DEFINE_BOOL(trace_dead_code_elimination, false, "trace dead code elimination")
     419             : DEFINE_BOOL(unreachable_code_elimination, true, "eliminate unreachable code")
     420             : DEFINE_BOOL(trace_osr, false, "trace on-stack replacement")
     421             : DEFINE_INT(stress_runs, 0, "number of stress runs")
     422             : DEFINE_BOOL(lookup_sample_by_shared, true,
     423             :             "when picking a function to optimize, watch for shared function "
     424             :             "info, not JSFunction itself")
     425             : DEFINE_BOOL(flush_optimized_code_cache, false,
     426             :             "flushes the cache of optimized code for closures on every GC")
     427             : DEFINE_BOOL(inline_construct, true, "inline constructor calls")
     428             : DEFINE_BOOL(inline_arguments, true, "inline functions with arguments object")
     429             : DEFINE_BOOL(inline_accessors, true, "inline JavaScript accessors")
     430             : DEFINE_BOOL(inline_into_try, true, "inline into try blocks")
     431             : DEFINE_INT(escape_analysis_iterations, 1,
     432             :            "maximum number of escape analysis fix-point iterations")
     433             : 
     434             : DEFINE_BOOL(concurrent_recompilation, true,
     435             :             "optimizing hot functions asynchronously on a separate thread")
     436             : DEFINE_BOOL(trace_concurrent_recompilation, false,
     437             :             "track concurrent recompilation")
     438             : DEFINE_INT(concurrent_recompilation_queue_length, 8,
     439             :            "the length of the concurrent compilation queue")
     440             : DEFINE_INT(concurrent_recompilation_delay, 0,
     441             :            "artificial compilation delay in ms")
     442             : DEFINE_BOOL(block_concurrent_recompilation, false,
     443             :             "block queued jobs until released")
     444             : 
     445             : DEFINE_BOOL(omit_map_checks_for_leaf_maps, true,
     446             :             "do not emit check maps for constant values that have a leaf map, "
     447             :             "deoptimize the optimized code if the layout of the maps changes.")
     448             : 
     449             : // Flags for TurboFan.
     450             : #ifdef V8_DISABLE_TURBO
     451             : // Allow to disable turbofan with a build flag after it's turned on by default.
     452             : #define TURBO_BOOL false
     453             : #else
     454             : #define TURBO_BOOL true
     455             : #endif
     456             : DEFINE_BOOL(turbo, TURBO_BOOL, "enable TurboFan compiler")
     457             : DEFINE_BOOL(turbo_sp_frame_access, false,
     458             :             "use stack pointer-relative access to frame wherever possible")
     459             : DEFINE_BOOL(turbo_preprocess_ranges, true,
     460             :             "run pre-register allocation heuristics")
     461             : DEFINE_STRING(turbo_filter, "~~", "optimization filter for TurboFan compiler")
     462             : DEFINE_BOOL(trace_turbo, false, "trace generated TurboFan IR")
     463             : DEFINE_BOOL(trace_turbo_graph, false, "trace generated TurboFan graphs")
     464      206204 : DEFINE_IMPLICATION(trace_turbo_graph, trace_turbo)
     465             : DEFINE_STRING(trace_turbo_cfg_file, NULL,
     466             :               "trace turbo cfg graph (for C1 visualizer) to a given file name")
     467             : DEFINE_BOOL(trace_turbo_types, true, "trace TurboFan's types")
     468             : DEFINE_BOOL(trace_turbo_scheduler, false, "trace TurboFan's scheduler")
     469             : DEFINE_BOOL(trace_turbo_reduction, false, "trace TurboFan's various reducers")
     470             : DEFINE_BOOL(trace_turbo_trimming, false, "trace TurboFan's graph trimmer")
     471             : DEFINE_BOOL(trace_turbo_jt, false, "trace TurboFan's jump threading")
     472             : DEFINE_BOOL(trace_turbo_ceq, false, "trace TurboFan's control equivalence")
     473             : DEFINE_BOOL(trace_turbo_loop, false, "trace TurboFan's loop optimizations")
     474             : DEFINE_BOOL(turbo_asm, true, "enable TurboFan for asm.js code")
     475             : DEFINE_BOOL(turbo_verify, DEBUG_BOOL, "verify TurboFan graphs at each phase")
     476             : DEFINE_STRING(turbo_verify_machine_graph, nullptr,
     477             :               "verify TurboFan machine graph before instruction selection")
     478             : #ifdef ENABLE_VERIFY_CSA
     479             : DEFINE_BOOL(verify_csa, DEBUG_BOOL,
     480             :             "verify TurboFan machine graph of code stubs")
     481             : #else
     482             : // Define the flag as read-only-false so that code still compiles even in the
     483             : // non-ENABLE_VERIFY_CSA configuration.
     484             : DEFINE_BOOL_READONLY(verify_csa, false,
     485             :                      "verify TurboFan machine graph of code stubs")
     486             : #endif
     487             : DEFINE_BOOL(trace_verify_csa, false, "trace code stubs verification")
     488             : DEFINE_STRING(csa_trap_on_node, nullptr,
     489             :               "trigger break point when a node with given id is created in "
     490             :               "given stub. The format is: StubName,NodeId")
     491             : DEFINE_BOOL(turbo_stats, false, "print TurboFan statistics")
     492             : DEFINE_BOOL(turbo_stats_nvp, false,
     493             :             "print TurboFan statistics in machine-readable format")
     494             : DEFINE_BOOL(turbo_splitting, true, "split nodes during scheduling in TurboFan")
     495             : DEFINE_BOOL(function_context_specialization, false,
     496             :             "enable function context specialization in TurboFan")
     497             : DEFINE_BOOL(turbo_inlining, true, "enable inlining in TurboFan")
     498             : DEFINE_BOOL(trace_turbo_inlining, false, "trace TurboFan inlining")
     499             : DEFINE_BOOL(turbo_load_elimination, true, "enable load elimination in TurboFan")
     500             : DEFINE_BOOL(trace_turbo_load_elimination, false,
     501             :             "trace TurboFan load elimination")
     502             : DEFINE_BOOL(loop_assignment_analysis, true, "perform loop assignment analysis")
     503             : DEFINE_BOOL(turbo_profiling, false, "enable profiling in TurboFan")
     504             : DEFINE_BOOL(turbo_verify_allocation, DEBUG_BOOL,
     505             :             "verify register allocation in TurboFan")
     506             : DEFINE_BOOL(turbo_move_optimization, true, "optimize gap moves in TurboFan")
     507             : DEFINE_BOOL(turbo_jt, true, "enable jump threading in TurboFan")
     508             : DEFINE_BOOL(turbo_loop_peeling, true, "Turbofan loop peeling")
     509             : DEFINE_BOOL(turbo_loop_variable, true, "Turbofan loop variable optimization")
     510             : DEFINE_BOOL(turbo_cf_optimization, true, "optimize control flow in TurboFan")
     511             : DEFINE_BOOL(turbo_frame_elision, true, "elide frames in TurboFan")
     512             : DEFINE_BOOL(turbo_escape, true, "enable escape analysis")
     513             : DEFINE_BOOL(turbo_instruction_scheduling, false,
     514             :             "enable instruction scheduling in TurboFan")
     515             : DEFINE_BOOL(turbo_stress_instruction_scheduling, false,
     516             :             "randomly schedule instructions to stress dependency tracking")
     517             : DEFINE_BOOL(turbo_store_elimination, true,
     518             :             "enable store-store elimination in TurboFan")
     519             : DEFINE_BOOL(turbo_experimental, false,
     520             :             "enable crashing features, for testing purposes only")
     521             : 
     522             : // Flags to help platform porters
     523             : DEFINE_BOOL(minimal, false,
     524             :             "simplifies execution model to make porting "
     525             :             "easier (e.g. always use Ignition, never use Crankshaft")
     526      206204 : DEFINE_IMPLICATION(minimal, ignition)
     527      206204 : DEFINE_NEG_IMPLICATION(minimal, crankshaft)
     528      206204 : DEFINE_NEG_IMPLICATION(minimal, use_ic)
     529             : 
     530             : // Flags for native WebAssembly.
     531             : DEFINE_BOOL(expose_wasm, true, "expose WASM interface to JavaScript")
     532             : DEFINE_BOOL(assume_asmjs_origin, false,
     533             :             "force wasm decoder to assume input is internal asm-wasm format")
     534             : DEFINE_BOOL(wasm_disable_structured_cloning, false,
     535             :             "disable WASM structured cloning")
     536             : DEFINE_INT(wasm_num_compilation_tasks, 10,
     537             :            "number of parallel compilation tasks for wasm")
     538             : DEFINE_BOOL(wasm_async_compilation, true,
     539             :             "enable actual asynchronous compilation for WebAssembly.compile")
     540             : // Parallel compilation confuses turbo_stats, force single threaded.
     541      206204 : DEFINE_VALUE_IMPLICATION(turbo_stats, wasm_num_compilation_tasks, 0)
     542             : DEFINE_UINT(wasm_max_mem_pages, v8::internal::wasm::kV8MaxWasmMemoryPages,
     543             :             "maximum memory size of a wasm instance")
     544             : DEFINE_UINT(wasm_max_table_size, v8::internal::wasm::kV8MaxWasmTableSize,
     545             :             "maximum table size of a wasm instance")
     546             : DEFINE_BOOL(trace_wasm_encoder, false, "trace encoding of wasm code")
     547             : DEFINE_BOOL(trace_wasm_decoder, false, "trace decoding of wasm code")
     548             : DEFINE_BOOL(trace_wasm_decode_time, false, "trace decoding time of wasm code")
     549             : DEFINE_BOOL(trace_wasm_compiler, false, "trace compiling of wasm code")
     550             : DEFINE_BOOL(trace_wasm_interpreter, false, "trace interpretation of wasm code")
     551             : DEFINE_INT(trace_wasm_ast_start, 0,
     552             :            "start function for WASM AST trace (inclusive)")
     553             : DEFINE_INT(trace_wasm_ast_end, 0, "end function for WASM AST trace (exclusive)")
     554             : DEFINE_UINT(skip_compiling_wasm_funcs, 0, "start compiling at function N")
     555             : DEFINE_BOOL(wasm_break_on_decoder_error, false,
     556             :             "debug break when wasm decoder encounters an error")
     557             : 
     558             : DEFINE_BOOL(validate_asm, false, "validate asm.js modules before compiling")
     559             : DEFINE_BOOL(fast_validate_asm, false,
     560             :             "validate asm.js modules before compiling")
     561             : DEFINE_BOOL(suppress_asm_messages, false,
     562             :             "don't emit asm.js related messages (for golden file testing)")
     563             : DEFINE_BOOL(trace_asm_time, false, "log asm.js timing info to the console")
     564             : DEFINE_BOOL(trace_asm_scanner, false,
     565             :             "log tokens encountered by asm.js scanner")
     566             : DEFINE_BOOL(trace_asm_parser, false, "verbose logging of asm.js parse failures")
     567             : DEFINE_BOOL(stress_validate_asm, false, "try to validate everything as asm.js")
     568             : 
     569             : DEFINE_BOOL(dump_wasm_module, false, "dump WASM module bytes")
     570             : DEFINE_STRING(dump_wasm_module_path, NULL, "directory to dump wasm modules to")
     571             : 
     572             : DEFINE_INT(typed_array_max_size_in_heap, 64,
     573             :            "threshold for in-heap typed array")
     574             : 
     575             : DEFINE_BOOL(wasm_simd_prototype, false,
     576             :             "enable prototype simd opcodes for wasm")
     577             : DEFINE_BOOL(wasm_eh_prototype, false,
     578             :             "enable prototype exception handling opcodes for wasm")
     579             : DEFINE_BOOL(wasm_mv_prototype, false,
     580             :             "enable prototype multi-value support for wasm")
     581             : DEFINE_BOOL(wasm_atomics_prototype, false,
     582             :             "enable prototype atomic opcodes for wasm")
     583             : 
     584             : DEFINE_BOOL(wasm_opt, true, "enable wasm optimization")
     585             : DEFINE_BOOL(wasm_no_bounds_checks, false,
     586             :             "disable bounds checks (performance testing only)")
     587             : DEFINE_BOOL(wasm_no_stack_checks, false,
     588             :             "disable stack checks (performance testing only)")
     589             : 
     590             : DEFINE_BOOL(wasm_trap_handler, false,
     591             :             "use signal handlers to catch out of bounds memory access in wasm"
     592             :             " (experimental, currently Linux x86_64 only)")
     593             : DEFINE_BOOL(wasm_guard_pages, false,
     594             :             "add guard pages to the end of WebWassembly memory"
     595             :             " (experimental, no effect on 32-bit)")
     596      206204 : DEFINE_IMPLICATION(wasm_trap_handler, wasm_guard_pages)
     597             : DEFINE_BOOL(wasm_code_fuzzer_gen_test, false,
     598             :             "Generate a test case when running the wasm-code fuzzer")
     599             : DEFINE_BOOL(print_wasm_code, false, "Print WebAssembly code")
     600             : DEFINE_BOOL(wasm_interpret_all, false,
     601             :             "Execute all wasm code in the wasm interpreter")
     602             : DEFINE_BOOL(asm_wasm_lazy_compilation, false,
     603             :             "enable lazy compilation for asm-wasm modules")
     604      206204 : DEFINE_IMPLICATION(validate_asm, asm_wasm_lazy_compilation)
     605             : DEFINE_BOOL(wasm_lazy_compilation, false,
     606             :             "enable lazy compilation for all wasm modules")
     607             : 
     608             : // Profiler flags.
     609             : DEFINE_INT(frame_count, 1, "number of stack frames inspected by the profiler")
     610             : // 0x1800 fits in the immediate field of an ARM instruction.
     611             : DEFINE_INT(interrupt_budget, 0x1800,
     612             :            "execution budget before interrupt is triggered")
     613             : DEFINE_INT(type_info_threshold, 25,
     614             :            "percentage of ICs that must have type info to allow optimization")
     615             : DEFINE_INT(generic_ic_threshold, 30,
     616             :            "max percentage of megamorphic/generic ICs to allow optimization")
     617             : DEFINE_INT(self_opt_count, 130, "call count before self-optimization")
     618             : 
     619             : DEFINE_BOOL(trace_opt_verbose, false, "extra verbose compilation tracing")
     620      206204 : DEFINE_IMPLICATION(trace_opt_verbose, trace_opt)
     621             : 
     622             : // Garbage collections flags.
     623             : DEFINE_INT(min_semi_space_size, 0,
     624             :            "min size of a semi-space (in MBytes), the new space consists of two"
     625             :            "semi-spaces")
     626             : DEFINE_INT(max_semi_space_size, 0,
     627             :            "max size of a semi-space (in MBytes), the new space consists of two"
     628             :            "semi-spaces")
     629             : DEFINE_INT(semi_space_growth_factor, 2, "factor by which to grow the new space")
     630             : DEFINE_BOOL(experimental_new_space_growth_heuristic, false,
     631             :             "Grow the new space based on the percentage of survivors instead "
     632             :             "of their absolute value.")
     633             : DEFINE_INT(max_old_space_size, 0, "max size of the old space (in Mbytes)")
     634             : DEFINE_INT(initial_old_space_size, 0, "initial old space size (in Mbytes)")
     635             : DEFINE_INT(max_executable_size, 0, "max size of executable memory (in Mbytes)")
     636             : DEFINE_BOOL(gc_global, false, "always perform global GCs")
     637             : DEFINE_INT(gc_interval, -1, "garbage collect after <n> allocations")
     638             : DEFINE_INT(retain_maps_for_n_gc, 2,
     639             :            "keeps maps alive for <n> old space garbage collections")
     640             : DEFINE_BOOL(trace_gc, false,
     641             :             "print one trace line following each garbage collection")
     642             : DEFINE_BOOL(trace_gc_nvp, false,
     643             :             "print one detailed trace line in name=value format "
     644             :             "after each garbage collection")
     645             : DEFINE_BOOL(trace_gc_ignore_scavenger, false,
     646             :             "do not print trace line after scavenger collection")
     647             : DEFINE_BOOL(trace_idle_notification, false,
     648             :             "print one trace line following each idle notification")
     649             : DEFINE_BOOL(trace_idle_notification_verbose, false,
     650             :             "prints the heap state used by the idle notification")
     651             : DEFINE_BOOL(trace_gc_verbose, false,
     652             :             "print more details following each garbage collection")
     653             : DEFINE_INT(trace_allocation_stack_interval, -1,
     654             :            "print stack trace after <n> free-list allocations")
     655             : DEFINE_BOOL(trace_fragmentation, false, "report fragmentation for old space")
     656             : DEFINE_BOOL(trace_fragmentation_verbose, false,
     657             :             "report fragmentation for old space (detailed)")
     658             : DEFINE_BOOL(trace_evacuation, false, "report evacuation statistics")
     659             : DEFINE_BOOL(trace_mutator_utilization, false,
     660             :             "print mutator utilization, allocation speed, gc speed")
     661             : DEFINE_BOOL(flush_code, true, "flush code that we expect not to use again")
     662             : DEFINE_BOOL(trace_code_flushing, false, "trace code flushing progress")
     663             : DEFINE_BOOL(age_code, true,
     664             :             "track un-executed functions to age code and flush only "
     665             :             "old code (required for code flushing)")
     666             : DEFINE_BOOL(incremental_marking, true, "use incremental marking")
     667             : DEFINE_BOOL(incremental_marking_wrappers, true,
     668             :             "use incremental marking for marking wrappers")
     669             : DEFINE_BOOL(concurrent_marking, false, "use concurrent marking")
     670             : DEFINE_BOOL(trace_concurrent_marking, false, "trace concurrent marking")
     671             : DEFINE_INT(min_progress_during_incremental_marking_finalization, 32,
     672             :            "keep finalizing incremental marking as long as we discover at "
     673             :            "least this many unmarked objects")
     674             : DEFINE_INT(max_incremental_marking_finalization_rounds, 3,
     675             :            "at most try this many times to finalize incremental marking")
     676             : DEFINE_BOOL(minor_mc, false, "perform young generation mark compact GCs")
     677      206204 : DEFINE_NEG_IMPLICATION(minor_mc, page_promotion)
     678      206204 : DEFINE_NEG_IMPLICATION(minor_mc, flush_code)
     679             : DEFINE_BOOL(black_allocation, true, "use black allocation")
     680             : DEFINE_BOOL(concurrent_store_buffer, true,
     681             :             "use concurrent store buffer processing")
     682             : DEFINE_BOOL(concurrent_sweeping, true, "use concurrent sweeping")
     683             : DEFINE_BOOL(parallel_compaction, true, "use parallel compaction")
     684             : DEFINE_BOOL(parallel_pointer_update, true,
     685             :             "use parallel pointer update during compaction")
     686             : DEFINE_BOOL(trace_incremental_marking, false,
     687             :             "trace progress of the incremental marking")
     688             : DEFINE_BOOL(track_gc_object_stats, false,
     689             :             "track object counts and memory usage")
     690             : DEFINE_BOOL(trace_gc_object_stats, false,
     691             :             "trace object counts and memory usage")
     692             : DEFINE_INT(gc_stats, 0, "Used by tracing internally to enable gc statistics")
     693      206204 : DEFINE_IMPLICATION(trace_gc_object_stats, track_gc_object_stats)
     694      206204 : DEFINE_VALUE_IMPLICATION(track_gc_object_stats, gc_stats, 1)
     695      206204 : DEFINE_VALUE_IMPLICATION(trace_gc_object_stats, gc_stats, 1)
     696      206204 : DEFINE_NEG_IMPLICATION(trace_gc_object_stats, incremental_marking)
     697             : DEFINE_BOOL(track_detached_contexts, true,
     698             :             "track native contexts that are expected to be garbage collected")
     699             : DEFINE_BOOL(trace_detached_contexts, false,
     700             :             "trace native contexts that are expected to be garbage collected")
     701      206204 : DEFINE_IMPLICATION(trace_detached_contexts, track_detached_contexts)
     702             : #ifdef VERIFY_HEAP
     703             : DEFINE_BOOL(verify_heap, false, "verify heap pointers before and after GC")
     704             : #endif
     705             : DEFINE_BOOL(move_object_start, true, "enable moving of object starts")
     706             : DEFINE_BOOL(memory_reducer, true, "use memory reducer")
     707             : DEFINE_INT(heap_growing_percent, 0,
     708             :            "specifies heap growing factor as (1 + heap_growing_percent/100)")
     709             : DEFINE_INT(v8_os_page_size, 0, "override OS page size (in KBytes)")
     710             : DEFINE_BOOL(always_compact, false, "Perform compaction on every full GC")
     711             : DEFINE_BOOL(never_compact, false,
     712             :             "Never perform compaction on full GC - testing only")
     713             : DEFINE_BOOL(compact_code_space, true, "Compact code space on full collections")
     714             : DEFINE_BOOL(cleanup_code_caches_at_gc, true,
     715             :             "Flush code caches in maps during mark compact cycle.")
     716             : DEFINE_BOOL(use_marking_progress_bar, true,
     717             :             "Use a progress bar to scan large objects in increments when "
     718             :             "incremental marking is active.")
     719             : DEFINE_BOOL(zap_code_space, DEBUG_BOOL,
     720             :             "Zap free memory in code space with 0xCC while sweeping.")
     721             : DEFINE_BOOL(force_marking_deque_overflows, false,
     722             :             "force overflows of marking deque by reducing it's size "
     723             :             "to 64 words")
     724             : DEFINE_BOOL(stress_compaction, false,
     725             :             "stress the GC compactor to flush out bugs (implies "
     726             :             "--force_marking_deque_overflows)")
     727             : DEFINE_BOOL(manual_evacuation_candidates_selection, false,
     728             :             "Test mode only flag. It allows an unit test to select evacuation "
     729             :             "candidates pages (requires --stress_compaction).")
     730             : DEFINE_BOOL(fast_promotion_new_space, false,
     731             :             "fast promote new space on high survival rates")
     732             : 
     733             : // assembler-ia32.cc / assembler-arm.cc / assembler-x64.cc
     734             : DEFINE_BOOL(debug_code, DEBUG_BOOL,
     735             :             "generate extra code (assertions) for debugging")
     736             : DEFINE_BOOL(code_comments, false, "emit comments in code disassembly")
     737             : DEFINE_BOOL(enable_sse3, true, "enable use of SSE3 instructions if available")
     738             : DEFINE_BOOL(enable_ssse3, true, "enable use of SSSE3 instructions if available")
     739             : DEFINE_BOOL(enable_sse4_1, true,
     740             :             "enable use of SSE4.1 instructions if available")
     741             : DEFINE_BOOL(enable_sahf, true,
     742             :             "enable use of SAHF instruction if available (X64 only)")
     743             : DEFINE_BOOL(enable_avx, true, "enable use of AVX instructions if available")
     744             : DEFINE_BOOL(enable_fma3, true, "enable use of FMA3 instructions if available")
     745             : DEFINE_BOOL(enable_bmi1, true, "enable use of BMI1 instructions if available")
     746             : DEFINE_BOOL(enable_bmi2, true, "enable use of BMI2 instructions if available")
     747             : DEFINE_BOOL(enable_lzcnt, true, "enable use of LZCNT instruction if available")
     748             : DEFINE_BOOL(enable_popcnt, true,
     749             :             "enable use of POPCNT instruction if available")
     750             : DEFINE_STRING(arm_arch, ARM_ARCH_DEFAULT,
     751             :               "generate instructions for the selected ARM architecture if "
     752             :               "available: armv6, armv7, armv7+sudiv or armv8")
     753             : DEFINE_BOOL(enable_vldr_imm, false,
     754             :             "enable use of constant pools for double immediate (ARM only)")
     755             : DEFINE_BOOL(force_long_branches, false,
     756             :             "force all emitted branches to be in long mode (MIPS/PPC only)")
     757             : DEFINE_STRING(mcpu, "auto", "enable optimization for specific cpu")
     758             : 
     759             : // Deprecated ARM flags (replaced by arm_arch).
     760             : DEFINE_MAYBE_BOOL(enable_armv7, "deprecated (use --arm_arch instead)")
     761             : DEFINE_MAYBE_BOOL(enable_vfp3, "deprecated (use --arm_arch instead)")
     762             : DEFINE_MAYBE_BOOL(enable_32dregs, "deprecated (use --arm_arch instead)")
     763             : DEFINE_MAYBE_BOOL(enable_neon, "deprecated (use --arm_arch instead)")
     764             : DEFINE_MAYBE_BOOL(enable_sudiv, "deprecated (use --arm_arch instead)")
     765             : DEFINE_MAYBE_BOOL(enable_armv8, "deprecated (use --arm_arch instead)")
     766             : 
     767             : // regexp-macro-assembler-*.cc
     768             : DEFINE_BOOL(enable_regexp_unaligned_accesses, true,
     769             :             "enable unaligned accesses for the regexp engine")
     770             : 
     771             : // api.cc
     772             : DEFINE_BOOL(script_streaming, true, "enable parsing on background")
     773             : DEFINE_BOOL(disable_old_api_accessors, false,
     774             :             "Disable old-style API accessors whose setters trigger through the "
     775             :             "prototype chain")
     776             : 
     777             : // bootstrapper.cc
     778             : DEFINE_STRING(expose_natives_as, NULL, "expose natives in global object")
     779             : DEFINE_BOOL(expose_free_buffer, false, "expose freeBuffer extension")
     780             : DEFINE_BOOL(expose_gc, false, "expose gc extension")
     781             : DEFINE_STRING(expose_gc_as, NULL,
     782             :               "expose gc extension under the specified name")
     783      206204 : DEFINE_IMPLICATION(expose_gc_as, expose_gc)
     784             : DEFINE_BOOL(expose_externalize_string, false,
     785             :             "expose externalize string extension")
     786             : DEFINE_BOOL(expose_trigger_failure, false, "expose trigger-failure extension")
     787             : DEFINE_INT(stack_trace_limit, 10, "number of stack frames to capture")
     788             : DEFINE_BOOL(builtins_in_stack_traces, false,
     789             :             "show built-in functions in stack traces")
     790             : 
     791             : // builtins.cc
     792             : DEFINE_BOOL(experimental_fast_array_builtins, false,
     793             :             "use experimental array builtins")
     794             : DEFINE_BOOL(allow_unsafe_function_constructor, false,
     795             :             "allow invoking the function constructor without security checks")
     796             : 
     797             : // builtins-ia32.cc
     798             : DEFINE_BOOL(inline_new, true, "use fast inline allocation")
     799             : 
     800             : // codegen-ia32.cc / codegen-arm.cc
     801             : DEFINE_BOOL(trace_codegen, false,
     802             :             "print name of functions for which code is generated")
     803             : DEFINE_BOOL(trace, false, "trace function calls")
     804             : DEFINE_BOOL(mask_constants_with_cookie, true,
     805             :             "use random jit cookie to mask large constants")
     806             : 
     807             : // codegen.cc
     808             : DEFINE_BOOL(lazy, true, "use lazy compilation")
     809             : DEFINE_BOOL(trace_opt, false, "trace lazy optimization")
     810             : DEFINE_BOOL(trace_opt_stats, false, "trace lazy optimization statistics")
     811             : DEFINE_BOOL(trace_file_names, false,
     812             :             "include file names in trace-opt/trace-deopt output")
     813             : DEFINE_BOOL(opt, true, "use adaptive optimizations")
     814             : DEFINE_BOOL(always_opt, false, "always try to optimize functions")
     815             : DEFINE_BOOL(always_osr, false, "always try to OSR functions")
     816             : DEFINE_BOOL(prepare_always_opt, false, "prepare for turning on always opt")
     817             : DEFINE_BOOL(trace_deopt, false, "trace optimize function deoptimization")
     818             : DEFINE_BOOL(trace_stub_failures, false,
     819             :             "trace deoptimization of generated code stubs")
     820             : 
     821             : DEFINE_BOOL(serialize_toplevel, true, "enable caching of toplevel scripts")
     822             : DEFINE_BOOL(serialize_eager, false, "compile eagerly when caching scripts")
     823             : DEFINE_BOOL(serialize_age_code, false, "pre age code in the code cache")
     824             : DEFINE_BOOL(trace_serializer, false, "print code serializer trace")
     825             : #ifdef DEBUG
     826             : DEFINE_BOOL(external_reference_stats, false,
     827             :             "print statistics on external references used during serialization")
     828             : #endif  // DEBUG
     829             : 
     830             : // compiler.cc
     831             : DEFINE_INT(max_deopt_count, 10,
     832             :            "maximum number of deoptimizations before giving up optimization of "
     833             :            "a function.")
     834             : 
     835             : // compilation-cache.cc
     836             : DEFINE_BOOL(compilation_cache, true, "enable compilation cache")
     837             : 
     838             : DEFINE_BOOL(cache_prototype_transitions, true, "cache prototype transitions")
     839             : 
     840             : // compiler-dispatcher.cc
     841             : DEFINE_BOOL(compiler_dispatcher, false, "enable compiler dispatcher")
     842             : DEFINE_BOOL(compiler_dispatcher_eager_inner, false,
     843             :             "enable background compilation of eager inner functions")
     844             : DEFINE_BOOL(trace_compiler_dispatcher, false,
     845             :             "trace compiler dispatcher activity")
     846             : 
     847             : // compiler-dispatcher-job.cc
     848             : DEFINE_BOOL(
     849             :     trace_compiler_dispatcher_jobs, false,
     850             :     "trace progress of individual jobs managed by the compiler dispatcher")
     851             : 
     852             : // cpu-profiler.cc
     853             : DEFINE_INT(cpu_profiler_sampling_interval, 1000,
     854             :            "CPU profiler sampling interval in microseconds")
     855             : 
     856             : // Array abuse tracing
     857             : DEFINE_BOOL(trace_js_array_abuse, false,
     858             :             "trace out-of-bounds accesses to JS arrays")
     859             : DEFINE_BOOL(trace_external_array_abuse, false,
     860             :             "trace out-of-bounds-accesses to external arrays")
     861             : DEFINE_BOOL(trace_array_abuse, false,
     862             :             "trace out-of-bounds accesses to all arrays")
     863      206204 : DEFINE_IMPLICATION(trace_array_abuse, trace_js_array_abuse)
     864      206204 : DEFINE_IMPLICATION(trace_array_abuse, trace_external_array_abuse)
     865             : 
     866             : // debugger
     867             : DEFINE_BOOL(enable_liveedit, true, "enable liveedit experimental feature")
     868             : DEFINE_BOOL(
     869             :     trace_side_effect_free_debug_evaluate, false,
     870             :     "print debug messages for side-effect-free debug-evaluate for testing")
     871             : DEFINE_BOOL(hard_abort, true, "abort by crashing")
     872             : 
     873             : // inspector
     874             : DEFINE_BOOL(expose_inspector_scripts, false,
     875             :             "expose injected-script-source.js for debugging")
     876             : 
     877             : // execution.cc
     878             : DEFINE_INT(stack_size, V8_DEFAULT_STACK_SIZE_KB,
     879             :            "default size of stack region v8 is allowed to use (in kBytes)")
     880             : 
     881             : // frames.cc
     882             : DEFINE_INT(max_stack_trace_source_length, 300,
     883             :            "maximum length of function source code printed in a stack trace.")
     884             : 
     885             : // full-codegen.cc
     886             : DEFINE_BOOL(always_inline_smi_code, false,
     887             :             "always inline smi code in non-opt code")
     888             : DEFINE_BOOL(verify_operand_stack_depth, false,
     889             :             "emit debug code that verifies the static tracking of the operand "
     890             :             "stack depth")
     891             : 
     892             : // execution.cc, messages.cc
     893             : DEFINE_BOOL(clear_exceptions_on_js_entry, false,
     894             :             "clear pending exceptions when entering JavaScript")
     895             : 
     896             : // counters.cc
     897             : DEFINE_INT(histogram_interval, 600000,
     898             :            "time interval in ms for aggregating memory histograms")
     899             : 
     900             : // heap-snapshot-generator.cc
     901             : DEFINE_BOOL(heap_profiler_trace_objects, false,
     902             :             "Dump heap object allocations/movements/size_updates")
     903             : 
     904             : 
     905             : // sampling-heap-profiler.cc
     906             : DEFINE_BOOL(sampling_heap_profiler_suppress_randomness, false,
     907             :             "Use constant sample intervals to eliminate test flakiness")
     908             : 
     909             : 
     910             : // v8.cc
     911             : DEFINE_BOOL(use_idle_notification, true,
     912             :             "Use idle notification to reduce memory footprint.")
     913             : // ic.cc
     914             : DEFINE_BOOL(use_ic, true, "use inline caching")
     915             : DEFINE_BOOL(trace_ic, false, "trace inline cache state transitions")
     916      206204 : DEFINE_IMPLICATION(trace_ic, log_code)
     917             : DEFINE_INT(ic_stats, 0, "inline cache state transitions statistics")
     918      206204 : DEFINE_VALUE_IMPLICATION(trace_ic, ic_stats, 1)
     919             : DEFINE_BOOL_READONLY(track_constant_fields, false,
     920             :                      "enable constant field tracking")
     921             : DEFINE_BOOL_READONLY(modify_map_inplace, false, "enable in-place map updates")
     922             : 
     923             : // macro-assembler-ia32.cc
     924             : DEFINE_BOOL(native_code_counters, false,
     925             :             "generate extra code for manipulating stats counters")
     926             : 
     927             : // objects.cc
     928             : DEFINE_BOOL(thin_strings, false, "Enable ThinString support")
     929             : DEFINE_BOOL(trace_weak_arrays, false, "Trace WeakFixedArray usage")
     930             : DEFINE_BOOL(trace_prototype_users, false,
     931             :             "Trace updates to prototype user tracking")
     932             : DEFINE_BOOL(use_verbose_printer, true, "allows verbose printing")
     933             : DEFINE_BOOL(trace_for_in_enumerate, false, "Trace for-in enumerate slow-paths")
     934             : #if TRACE_MAPS
     935             : DEFINE_BOOL(trace_maps, false, "trace map creation")
     936             : #endif
     937             : 
     938             : // preparser.cc
     939             : DEFINE_BOOL(use_parse_tasks, false, "use parse tasks")
     940             : DEFINE_BOOL(trace_parse_tasks, false, "trace parse task creation")
     941             : 
     942             : // parser.cc
     943             : DEFINE_BOOL(allow_natives_syntax, false, "allow natives syntax")
     944             : DEFINE_BOOL(trace_parse, false, "trace parsing and preparsing")
     945             : DEFINE_BOOL(trace_preparse, false, "trace preparsing decisions")
     946             : DEFINE_BOOL(lazy_inner_functions, true, "enable lazy parsing inner functions")
     947             : DEFINE_BOOL(aggressive_lazy_inner_functions, false,
     948             :             "even lazier inner function parsing")
     949      206204 : DEFINE_IMPLICATION(aggressive_lazy_inner_functions, lazy_inner_functions)
     950             : DEFINE_BOOL(experimental_preparser_scope_analysis, false,
     951             :             "perform scope analysis for preparsed inner functions")
     952      206204 : DEFINE_IMPLICATION(experimental_preparser_scope_analysis, lazy_inner_functions)
     953             : 
     954             : // simulator-arm.cc, simulator-arm64.cc and simulator-mips.cc
     955             : DEFINE_BOOL(trace_sim, false, "Trace simulator execution")
     956             : DEFINE_BOOL(debug_sim, false, "Enable debugging the simulator")
     957             : DEFINE_BOOL(check_icache, false,
     958             :             "Check icache flushes in ARM and MIPS simulator")
     959             : DEFINE_INT(stop_sim_at, 0, "Simulator stop after x number of instructions")
     960             : #if defined(V8_TARGET_ARCH_ARM64) || defined(V8_TARGET_ARCH_MIPS64) || \
     961             :     defined(V8_TARGET_ARCH_PPC64)
     962             : DEFINE_INT(sim_stack_alignment, 16,
     963             :            "Stack alignment in bytes in simulator. This must be a power of two "
     964             :            "and it must be at least 16. 16 is default.")
     965             : #else
     966             : DEFINE_INT(sim_stack_alignment, 8,
     967             :            "Stack alingment in bytes in simulator (4 or 8, 8 is default)")
     968             : #endif
     969             : DEFINE_INT(sim_stack_size, 2 * MB / KB,
     970             :            "Stack size of the ARM64, MIPS64 and PPC64 simulator "
     971             :            "in kBytes (default is 2 MB)")
     972             : DEFINE_BOOL(log_regs_modified, true,
     973             :             "When logging register values, only print modified registers.")
     974             : DEFINE_BOOL(log_colour, ENABLE_LOG_COLOUR,
     975             :             "When logging, try to use coloured output.")
     976             : DEFINE_BOOL(ignore_asm_unimplemented_break, false,
     977             :             "Don't break for ASM_UNIMPLEMENTED_BREAK macros.")
     978             : DEFINE_BOOL(trace_sim_messages, false,
     979             :             "Trace simulator debug messages. Implied by --trace-sim.")
     980             : 
     981             : // isolate.cc
     982             : DEFINE_BOOL(stack_trace_on_illegal, false,
     983             :             "print stack trace when an illegal exception is thrown")
     984             : DEFINE_BOOL(abort_on_uncaught_exception, false,
     985             :             "abort program (dump core) when an uncaught exception is thrown")
     986             : DEFINE_BOOL(abort_on_stack_overflow, false,
     987             :             "Abort program when stack overflow (as opposed to throwing "
     988             :             "RangeError). This is useful for fuzzing where the spec behaviour "
     989             :             "would introduce nondeterminism.")
     990             : DEFINE_BOOL(randomize_hashes, true,
     991             :             "randomize hashes to avoid predictable hash collisions "
     992             :             "(with snapshots this option cannot override the baked-in seed)")
     993             : DEFINE_INT(hash_seed, 0,
     994             :            "Fixed seed to use to hash property keys (0 means random)"
     995             :            "(with snapshots this option cannot override the baked-in seed)")
     996             : DEFINE_INT(random_seed, 0,
     997             :            "Default seed for initializing random generator "
     998             :            "(0, the default, means to use system random).")
     999             : DEFINE_BOOL(trace_rail, false, "trace RAIL mode")
    1000             : DEFINE_BOOL(print_all_exceptions, false,
    1001             :             "print exception object and stack trace on each thrown exception")
    1002             : 
    1003             : // runtime.cc
    1004             : DEFINE_BOOL(runtime_call_stats, false, "report runtime call counts and times")
    1005             : DEFINE_INT(runtime_stats, 0,
    1006             :            "internal usage only for controlling runtime statistics")
    1007      206204 : DEFINE_VALUE_IMPLICATION(runtime_call_stats, runtime_stats, 1)
    1008             : 
    1009             : // snapshot-common.cc
    1010             : DEFINE_BOOL(profile_deserialization, false,
    1011             :             "Print the time it takes to deserialize the snapshot.")
    1012             : DEFINE_BOOL(serialization_statistics, false,
    1013             :             "Collect statistics on serialized objects.")
    1014             : 
    1015             : // Regexp
    1016             : DEFINE_BOOL(regexp_optimization, true, "generate optimized regexp code")
    1017             : 
    1018             : // Testing flags test/cctest/test-{flags,api,serialization}.cc
    1019             : DEFINE_BOOL(testing_bool_flag, true, "testing_bool_flag")
    1020             : DEFINE_MAYBE_BOOL(testing_maybe_bool_flag, "testing_maybe_bool_flag")
    1021             : DEFINE_INT(testing_int_flag, 13, "testing_int_flag")
    1022             : DEFINE_FLOAT(testing_float_flag, 2.5, "float-flag")
    1023             : DEFINE_STRING(testing_string_flag, "Hello, world!", "string-flag")
    1024             : DEFINE_INT(testing_prng_seed, 42, "Seed used for threading test randomness")
    1025             : 
    1026             : // mksnapshot.cc
    1027             : DEFINE_STRING(startup_src, NULL,
    1028             :               "Write V8 startup as C++ src. (mksnapshot only)")
    1029             : DEFINE_STRING(startup_blob, NULL,
    1030             :               "Write V8 startup blob file. (mksnapshot only)")
    1031             : 
    1032             : // code-stubs-hydrogen.cc
    1033             : DEFINE_BOOL(profile_hydrogen_code_stub_compilation, false,
    1034             :             "Print the time it takes to lazily compile hydrogen code stubs.")
    1035             : 
    1036             : //
    1037             : // Dev shell flags
    1038             : //
    1039             : 
    1040             : DEFINE_BOOL(help, false, "Print usage message, including flags, on console")
    1041             : DEFINE_BOOL(dump_counters, false, "Dump counters on exit")
    1042             : DEFINE_BOOL(dump_counters_nvp, false,
    1043             :             "Dump counters as name-value pairs on exit")
    1044             : DEFINE_BOOL(use_external_strings, false, "Use external strings for source code")
    1045             : 
    1046             : DEFINE_STRING(map_counters, "", "Map counters to a file")
    1047             : DEFINE_ARGS(js_arguments,
    1048             :             "Pass all remaining arguments to the script. Alias for \"--\".")
    1049             : 
    1050             : //
    1051             : // GDB JIT integration flags.
    1052             : //
    1053             : #undef FLAG
    1054             : #ifdef ENABLE_GDB_JIT_INTERFACE
    1055             : #define FLAG FLAG_FULL
    1056             : #else
    1057             : #define FLAG FLAG_READONLY
    1058             : #endif
    1059             : 
    1060             : DEFINE_BOOL(gdbjit, false, "enable GDBJIT interface")
    1061             : DEFINE_BOOL(gdbjit_full, false, "enable GDBJIT interface for all code objects")
    1062             : DEFINE_BOOL(gdbjit_dump, false, "dump elf objects with debug info to disk")
    1063             : DEFINE_STRING(gdbjit_dump_filter, "",
    1064             :               "dump only objects containing this substring")
    1065             : 
    1066             : #ifdef ENABLE_GDB_JIT_INTERFACE
    1067      206204 : DEFINE_IMPLICATION(gdbjit_full, gdbjit)
    1068      206204 : DEFINE_IMPLICATION(gdbjit_dump, gdbjit)
    1069             : #endif
    1070      206204 : DEFINE_NEG_IMPLICATION(gdbjit, compact_code_space)
    1071             : 
    1072             : //
    1073             : // Debug only flags
    1074             : //
    1075             : #undef FLAG
    1076             : #ifdef DEBUG
    1077             : #define FLAG FLAG_FULL
    1078             : #else
    1079             : #define FLAG FLAG_READONLY
    1080             : #endif
    1081             : 
    1082             : // checks.cc
    1083             : #ifdef ENABLE_SLOW_DCHECKS
    1084             : DEFINE_BOOL(enable_slow_asserts, false,
    1085             :             "enable asserts that are slow to execute")
    1086             : #endif
    1087             : 
    1088             : // codegen-ia32.cc / codegen-arm.cc / macro-assembler-*.cc
    1089             : DEFINE_BOOL(print_ast, false, "print source AST")
    1090             : DEFINE_BOOL(print_builtin_ast, false, "print source AST for builtins")
    1091             : DEFINE_BOOL(trap_on_abort, false, "replace aborts by breakpoints")
    1092             : 
    1093             : // compiler.cc
    1094             : DEFINE_BOOL(print_builtin_scopes, false, "print scopes for builtins")
    1095             : DEFINE_BOOL(print_scopes, false, "print scopes")
    1096             : 
    1097             : // contexts.cc
    1098             : DEFINE_BOOL(trace_contexts, false, "trace contexts operations")
    1099             : 
    1100             : // heap.cc
    1101             : DEFINE_BOOL(gc_verbose, false, "print stuff during garbage collection")
    1102             : DEFINE_BOOL(heap_stats, false, "report heap statistics before and after GC")
    1103             : DEFINE_BOOL(code_stats, false, "report code statistics after GC")
    1104             : DEFINE_BOOL(print_handles, false, "report handles after GC")
    1105             : DEFINE_BOOL(check_handle_count, false,
    1106             :             "Check that there are not too many handles at GC")
    1107             : DEFINE_BOOL(print_global_handles, false, "report global handles after GC")
    1108             : 
    1109             : // TurboFan debug-only flags.
    1110             : DEFINE_BOOL(trace_turbo_escape, false, "enable tracing in escape analysis")
    1111             : 
    1112             : // objects.cc
    1113             : DEFINE_BOOL(trace_normalization, false,
    1114             :             "prints when objects are turned into dictionaries.")
    1115             : 
    1116             : // runtime.cc
    1117             : DEFINE_BOOL(trace_lazy, false, "trace lazy compilation")
    1118             : 
    1119             : // spaces.cc
    1120             : DEFINE_BOOL(collect_heap_spill_statistics, false,
    1121             :             "report heap spill statistics along with heap_stats "
    1122             :             "(requires heap_stats)")
    1123             : DEFINE_BOOL(trace_live_bytes, false,
    1124             :             "trace incrementing and resetting of live bytes")
    1125             : DEFINE_BOOL(trace_isolates, false, "trace isolate state changes")
    1126             : 
    1127             : // Regexp
    1128             : DEFINE_BOOL(regexp_possessive_quantifier, false,
    1129             :             "enable possessive quantifier syntax for testing")
    1130             : DEFINE_BOOL(trace_regexp_bytecodes, false, "trace regexp bytecode execution")
    1131             : DEFINE_BOOL(trace_regexp_assembler, false,
    1132             :             "trace regexp macro assembler calls.")
    1133             : DEFINE_BOOL(trace_regexp_parser, false, "trace regexp parsing")
    1134             : 
    1135             : // Debugger
    1136             : DEFINE_BOOL(print_break_location, false, "print source location on debug break")
    1137             : 
    1138             : // wasm instance management
    1139             : DEFINE_BOOL(trace_wasm_instances, false,
    1140             :             "trace creation and collection of wasm instances")
    1141             : 
    1142             : //
    1143             : // Logging and profiling flags
    1144             : //
    1145             : #undef FLAG
    1146             : #define FLAG FLAG_FULL
    1147             : 
    1148             : // log.cc
    1149             : DEFINE_BOOL(log, false,
    1150             :             "Minimal logging (no API, code, GC, suspect, or handles samples).")
    1151             : DEFINE_BOOL(log_all, false, "Log all events to the log file.")
    1152             : DEFINE_BOOL(log_api, false, "Log API events to the log file.")
    1153             : DEFINE_BOOL(log_code, false,
    1154             :             "Log code events to the log file without profiling.")
    1155             : DEFINE_BOOL(log_gc, false,
    1156             :             "Log heap samples on garbage collection for the hp2ps tool.")
    1157             : DEFINE_BOOL(log_handles, false, "Log global handle events.")
    1158             : DEFINE_BOOL(log_suspect, false, "Log suspect operations.")
    1159             : DEFINE_BOOL(prof, false,
    1160             :             "Log statistical profiling information (implies --log-code).")
    1161             : 
    1162             : #if defined(ANDROID)
    1163             : // Phones and tablets have processors that are much slower than desktop
    1164             : // and laptop computers for which current heuristics are tuned.
    1165             : #define DEFAULT_PROF_SAMPLING_INTERVAL 5000
    1166             : #else
    1167             : #define DEFAULT_PROF_SAMPLING_INTERVAL 1000
    1168             : #endif
    1169             : DEFINE_INT(prof_sampling_interval, DEFAULT_PROF_SAMPLING_INTERVAL,
    1170             :            "Interval for --prof samples (in microseconds).")
    1171             : #undef DEFAULT_PROF_SAMPLING_INTERVAL
    1172             : 
    1173             : DEFINE_BOOL(prof_cpp, false, "Like --prof, but ignore generated code.")
    1174      206204 : DEFINE_IMPLICATION(prof, prof_cpp)
    1175             : DEFINE_BOOL(prof_browser_mode, true,
    1176             :             "Used with --prof, turns on browser-compatible mode for profiling.")
    1177             : DEFINE_STRING(logfile, "v8.log", "Specify the name of the log file.")
    1178             : DEFINE_BOOL(logfile_per_isolate, true, "Separate log files for each isolate.")
    1179             : DEFINE_BOOL(ll_prof, false, "Enable low-level linux profiler.")
    1180             : DEFINE_BOOL(perf_basic_prof, false,
    1181             :             "Enable perf linux profiler (basic support).")
    1182      206204 : DEFINE_NEG_IMPLICATION(perf_basic_prof, compact_code_space)
    1183             : DEFINE_BOOL(perf_basic_prof_only_functions, false,
    1184             :             "Only report function code ranges to perf (i.e. no stubs).")
    1185      206204 : DEFINE_IMPLICATION(perf_basic_prof_only_functions, perf_basic_prof)
    1186             : DEFINE_BOOL(perf_prof, false,
    1187             :             "Enable perf linux profiler (experimental annotate support).")
    1188      206204 : DEFINE_NEG_IMPLICATION(perf_prof, compact_code_space)
    1189             : DEFINE_BOOL(perf_prof_unwinding_info, false,
    1190             :             "Enable unwinding info for perf linux profiler (experimental).")
    1191      206204 : DEFINE_IMPLICATION(perf_prof, perf_prof_unwinding_info)
    1192             : DEFINE_STRING(gc_fake_mmap, "/tmp/__v8_gc__",
    1193             :               "Specify the name of the file for fake gc mmap used in ll_prof")
    1194             : DEFINE_BOOL(log_internal_timer_events, false, "Time internal events.")
    1195             : DEFINE_BOOL(log_timer_events, false,
    1196             :             "Time events including external callbacks.")
    1197      206204 : DEFINE_IMPLICATION(log_timer_events, log_internal_timer_events)
    1198      206204 : DEFINE_IMPLICATION(log_internal_timer_events, prof)
    1199             : DEFINE_BOOL(log_instruction_stats, false, "Log AArch64 instruction statistics.")
    1200             : DEFINE_STRING(log_instruction_file, "arm64_inst.csv",
    1201             :               "AArch64 instruction statistics log file.")
    1202             : DEFINE_INT(log_instruction_period, 1 << 22,
    1203             :            "AArch64 instruction statistics logging period.")
    1204             : 
    1205             : DEFINE_BOOL(redirect_code_traces, false,
    1206             :             "output deopt information and disassembly into file "
    1207             :             "code-<pid>-<isolate id>.asm")
    1208             : DEFINE_STRING(redirect_code_traces_to, NULL,
    1209             :               "output deopt information and disassembly into the given file")
    1210             : 
    1211             : DEFINE_BOOL(hydrogen_track_positions, false,
    1212             :             "track source code positions when building IR")
    1213             : 
    1214             : DEFINE_BOOL(print_opt_source, false,
    1215             :             "print source code of optimized and inlined functions")
    1216      206204 : DEFINE_IMPLICATION(hydrogen_track_positions, print_opt_source)
    1217             : 
    1218             : //
    1219             : // Disassembler only flags
    1220             : //
    1221             : #undef FLAG
    1222             : #ifdef ENABLE_DISASSEMBLER
    1223             : #define FLAG FLAG_FULL
    1224             : #else
    1225             : #define FLAG FLAG_READONLY
    1226             : #endif
    1227             : 
    1228             : // elements.cc
    1229             : DEFINE_BOOL(trace_elements_transitions, false, "trace elements transitions")
    1230             : 
    1231             : DEFINE_BOOL(trace_creation_allocation_sites, false,
    1232             :             "trace the creation of allocation sites")
    1233             : 
    1234             : // code-stubs.cc
    1235             : DEFINE_BOOL(print_code_stubs, false, "print code stubs")
    1236             : DEFINE_BOOL(test_secondary_stub_cache, false,
    1237             :             "test secondary stub cache by disabling the primary one")
    1238             : 
    1239             : DEFINE_BOOL(test_primary_stub_cache, false,
    1240             :             "test primary stub cache by disabling the secondary one")
    1241             : 
    1242             : DEFINE_BOOL(test_small_max_function_context_stub_size, false,
    1243             :             "enable testing the function context size overflow path "
    1244             :             "by making the maximum size smaller")
    1245             : 
    1246             : // codegen-ia32.cc / codegen-arm.cc
    1247             : DEFINE_BOOL(print_code, false, "print generated code")
    1248             : DEFINE_BOOL(print_opt_code, false, "print optimized code")
    1249             : DEFINE_STRING(print_opt_code_filter, "*", "filter for printing optimized code")
    1250             : DEFINE_BOOL(print_unopt_code, false,
    1251             :             "print unoptimized code before "
    1252             :             "printing optimized code based on it")
    1253             : DEFINE_BOOL(print_code_verbose, false, "print more information for code")
    1254             : DEFINE_BOOL(print_builtin_code, false, "print generated code for builtins")
    1255             : 
    1256             : #ifdef ENABLE_DISASSEMBLER
    1257             : DEFINE_BOOL(sodium, false,
    1258             :             "print generated code output suitable for use with "
    1259             :             "the Sodium code viewer")
    1260             : 
    1261             : DEFINE_IMPLICATION(sodium, print_code_stubs)
    1262             : DEFINE_IMPLICATION(sodium, print_code)
    1263             : DEFINE_IMPLICATION(sodium, print_opt_code)
    1264             : DEFINE_IMPLICATION(sodium, hydrogen_track_positions)
    1265             : DEFINE_IMPLICATION(sodium, code_comments)
    1266             : 
    1267             : DEFINE_BOOL(print_all_code, false, "enable all flags related to printing code")
    1268             : DEFINE_IMPLICATION(print_all_code, print_code)
    1269             : DEFINE_IMPLICATION(print_all_code, print_opt_code)
    1270             : DEFINE_IMPLICATION(print_all_code, print_unopt_code)
    1271             : DEFINE_IMPLICATION(print_all_code, print_code_verbose)
    1272             : DEFINE_IMPLICATION(print_all_code, print_builtin_code)
    1273             : DEFINE_IMPLICATION(print_all_code, print_code_stubs)
    1274             : DEFINE_IMPLICATION(print_all_code, code_comments)
    1275             : #ifdef DEBUG
    1276             : DEFINE_IMPLICATION(print_all_code, trace_codegen)
    1277             : #endif
    1278             : #endif
    1279             : 
    1280             : #undef FLAG
    1281             : #define FLAG FLAG_FULL
    1282             : 
    1283             : //
    1284             : // Predictable mode related flags.
    1285             : //
    1286             : 
    1287             : DEFINE_BOOL(predictable, false, "enable predictable mode")
    1288      206204 : DEFINE_IMPLICATION(predictable, single_threaded)
    1289      206204 : DEFINE_NEG_IMPLICATION(predictable, memory_reducer)
    1290      206204 : DEFINE_VALUE_IMPLICATION(single_threaded, wasm_num_compilation_tasks, 0)
    1291             : 
    1292             : //
    1293             : // Threading related flags.
    1294             : //
    1295             : 
    1296             : DEFINE_BOOL(single_threaded, false, "disable the use of background tasks")
    1297      206204 : DEFINE_NEG_IMPLICATION(single_threaded, concurrent_recompilation)
    1298      206204 : DEFINE_NEG_IMPLICATION(single_threaded, concurrent_marking)
    1299      206204 : DEFINE_NEG_IMPLICATION(single_threaded, concurrent_sweeping)
    1300      206204 : DEFINE_NEG_IMPLICATION(single_threaded, parallel_compaction)
    1301      206204 : DEFINE_NEG_IMPLICATION(single_threaded, parallel_pointer_update)
    1302      206204 : DEFINE_NEG_IMPLICATION(single_threaded, concurrent_store_buffer)
    1303      206204 : DEFINE_NEG_IMPLICATION(single_threaded, compiler_dispatcher)
    1304             : 
    1305             : #undef FLAG
    1306             : 
    1307             : #ifdef VERIFY_PREDICTABLE
    1308             : #define FLAG FLAG_FULL
    1309             : #else
    1310             : #define FLAG FLAG_READONLY
    1311             : #endif
    1312             : 
    1313             : DEFINE_BOOL(verify_predictable, false,
    1314             :             "this mode is used for checking that V8 behaves predictably")
    1315             : DEFINE_INT(dump_allocations_digest_at_alloc, -1,
    1316             :            "dump allocations digest each n-th allocation")
    1317             : 
    1318             : //
    1319             : // Read-only flags
    1320             : //
    1321             : #undef FLAG
    1322             : #define FLAG FLAG_READONLY
    1323             : 
    1324             : // assembler.h
    1325             : DEFINE_BOOL(enable_embedded_constant_pool, V8_EMBEDDED_CONSTANT_POOL,
    1326             :             "enable use of embedded constant pools (PPC only)")
    1327             : 
    1328             : DEFINE_BOOL(unbox_double_fields, V8_DOUBLE_FIELDS_UNBOXING,
    1329             :             "enable in-object double fields unboxing (64-bit only)")
    1330      206204 : DEFINE_IMPLICATION(unbox_double_fields, track_double_fields)
    1331             : 
    1332             : // Cleanup...
    1333             : #undef FLAG_FULL
    1334             : #undef FLAG_READONLY
    1335             : #undef FLAG
    1336             : #undef FLAG_ALIAS
    1337             : 
    1338             : #undef DEFINE_BOOL
    1339             : #undef DEFINE_MAYBE_BOOL
    1340             : #undef DEFINE_INT
    1341             : #undef DEFINE_STRING
    1342             : #undef DEFINE_FLOAT
    1343             : #undef DEFINE_ARGS
    1344             : #undef DEFINE_IMPLICATION
    1345             : #undef DEFINE_NEG_IMPLICATION
    1346             : #undef DEFINE_NEG_VALUE_IMPLICATION
    1347             : #undef DEFINE_VALUE_IMPLICATION
    1348             : #undef DEFINE_ALIAS_BOOL
    1349             : #undef DEFINE_ALIAS_INT
    1350             : #undef DEFINE_ALIAS_STRING
    1351             : #undef DEFINE_ALIAS_FLOAT
    1352             : #undef DEFINE_ALIAS_ARGS
    1353             : 
    1354             : #undef FLAG_MODE_DECLARE
    1355             : #undef FLAG_MODE_DEFINE
    1356             : #undef FLAG_MODE_DEFINE_DEFAULTS
    1357             : #undef FLAG_MODE_META
    1358             : #undef FLAG_MODE_DEFINE_IMPLICATIONS
    1359             : 
    1360             : #undef COMMA

Generated by: LCOV version 1.10