Skip to content

Instantly share code, notes, and snippets.

@azenla
Created December 14, 2014 21:30
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save azenla/c21c928c585fb39f2c60 to your computer and use it in GitHub Desktop.
Save azenla/c21c928c585fb39f2c60 to your computer and use it in GitHub Desktop.
Dart VM Options
[kaendfinger@localhost Dart]$ dart --help -v
Usage: dart [<vm-flags>] <dart-script-file> [<dart-options>]
Executes the Dart script passed as <dart-script-file>.
Supported options:
--checked or -c
Insert runtime type checks and enable assertions (checked mode).
--help or -h
Display this message (add -v or --verbose for information about
all VM options).
--package-root=<path> or -p<path>
Where to find packages, that is, "package:..." imports.
--version
Print the VM version.
--debug[:<port number>]
enables debugging and listens on specified port for debugger connections
(default port number is 5858)
--break-at=<location>
sets a breakpoint at specified location where <location> is one of :
url:<line_num> e.g. test.dart:10
[<class_name>.]<function_name> e.g. B.foo
--snapshot=<file_name>
loads Dart script and generates a snapshot in the specified file
--print-script
generates Dart source code back and prints it after parsing a Dart script
--enable-vm-service[:<port number>]
enables the VM service and listens on specified port for connections
(default port number is 8181)
The following options are only used for VM development and may
be changed in any future version:
Flag settings:
allocation_sinking: true (Attempt to sink temporary allocations to side exits)
always_drop_code: false (Always try to drop code if the function's usage counter is >= 0)
array_bounds_check_elimination: true (Eliminate redundant bounds checks.)
break_at_isolate_spawn: false (Insert a one-time breakpoint at the entrypoint for all spawned isolates)
check_function_fingerprints: false (Check function fingerprints)
checked: (Enable checked mode.)
code_collection_interval_in_us: 30000000 (Time between attempts to collect unused code.)
code_comments: false (Include comments into code and disassembly)
collect_code: true (Attempt to GC infrequently used code.)
common_subexpression_elimination: true (Do common subexpression elimination.)
compiler_stats: false (Compiler stat counters.)
compress_deopt_info: true (Compress the size of the deoptimization info for optimized code.)
concurrent_sweep: true (Concurrent sweep for old generation.)
constant_propagation: true (Do conditional constant propagation/unreachable code elimination.)
coverage_dir: (null) (Enable writing coverage data into specified directory.)
dead_store_elimination: true (Eliminate dead stores)
deoptimization_counter_inlining_threshold: 12 (How many times we allow deoptimization before we stop inlining.)
deoptimization_counter_threshold: 16 (How many times we allow deoptimization before we disallow optimization.)
deoptimize_alot: false (Deoptimizes all live frames when we are about to return to Dart code from native entries.)
deoptimize_every: 0 (Deoptimize on every N stack overflow checks)
deoptimize_filter: (null) (Deoptimize in named function on stack overflow checks)
disable_alloc_stubs_after_gc: false (Stress testing flag.)
disassemble: false (Disassemble dart code.)
disassemble_optimized: false (Disassemble optimized code.)
disassemble_stubs: false (Disassemble generated stubs.)
dump_symbol_stats: false (Dump symbol table statistics)
early_tenuring_threshold: 66 (When more than this percentage of promotion candidates survive, promote all survivors of next scavenge.)
eliminate_type_checks: true (Eliminate type checks when allowed by static type analysis.)
emit_edge_counters: true (Emit edge counters at targets.)
enable_asserts: false (Enable assert statements.)
enable_async: false (Enable async operations.)
enable_checked_mode: (Enable checked mode.)
enable_inlining_annotations: false (Enable inlining annotations)
enable_simd_inline: true (Enable inlining of SIMD related method calls.)
enable_type_checks: false (Enable type checks.)
error_on_bad_override: false (Report error for bad overrides.)
error_on_bad_type: false (Report error for malformed types.)
gc_at_alloc: false (GC at every allocation.)
generate_gdb_symbols: false (Generate symbols of generated dart functions for debugging with GDB)
generate_perf_events_symbols: false (Generate events symbols for profiling with perf)
generate_perf_jitdump: false (Writes jitdump data for profiling with perf annotate)
getter_setter_ratio: 13 (Ratio of getter/setter usage used for double field unboxing heuristics)
heap_growth_rate: 0 (The max number of pages the heap can grow at a time)
huge_method_cutoff_in_code_size: 200000 (Huge method cutoff in unoptimized code size (in bytes).)
huge_method_cutoff_in_tokens: 20000 (Huge method cutoff in tokens: Disables optimizations for huge methods.)
ignore_unrecognized_flags: false (Ignore unrecognized flags.)
inline_alloc: true (Inline allocation of objects.)
inline_getters_setters_smaller_than: 10 (Always inline getters and setters that have fewer instructions)
inlining_callee_call_sites_threshold: 1 (Always inline functions containing threshold or fewer calls.)
inlining_callee_size_threshold: 80 (Do not inline callees larger than threshold)
inlining_caller_size_threshold: 50000 (Stop inlining once caller reaches the threshold.)
inlining_constant_arguments_count: 1 (Inline function calls with sufficient constant arguments and up to the increased threshold on instructions)
inlining_constant_arguments_size_threshold: 60 (Inline function calls with sufficient constant arguments and up to the increased threshold on instructions)
inlining_depth_threshold: 6 (Inline function calls up to threshold nesting depth)
inlining_filter: (null) (Inline only in named function)
inlining_hotness: 10 (Inline only hotter calls, in percents (0 .. 100); default 10%: calls above-equal 10% of max-count are inlined.)
inlining_recursion_depth_threshold: 1 (Inline recursive function calls up to threshold recursion depth.)
inlining_size_threshold: 25 (Always inline functions that have threshold or fewer instructions)
intrinsify: true (Instrinsify when possible)
load_cse: true (Use redundant load elimination.)
log_code_drop: false (Emit a log message when pointers to unused code are dropped.)
log_growth: false (Log PageSpace growth policy decisions.)
loop_invariant_code_motion: true (Do loop invariant code motion.)
max_equality_polymorphic_checks: 32 (Maximum number of polymorphic checks in equality operator, otherwise use megamorphic dispatch.)
max_inlined_per_depth: 500 (Max. number of inlined calls per depth)
max_polymorphic_checks: 4 (Maximum number of polymorphic check, otherwise it is megamorphic.)
max_subtype_cache_entries: 100 (Maximum number of subtype cache entries (number of checks cached).)
min_optimization_counter_threshold: 5000 (The minimum invocation count for a function.)
new_gen_ext_limit: 64 (maximum total external size (MB) in new gen before triggering GC)
new_gen_garbage_threshold: 90 (Grow new gen when less than this percentage is garbage.)
new_gen_growth_factor: 4 (Grow new gen by this factor.)
new_gen_semi_max_size: 32 (Max size of new gen semi space in MB)
old_gen_growth_rate: 280 (The max number of pages the old generation can grow at a time)
old_gen_growth_space_ratio: 20 (The desired maximum percentage of free space after old gen GC)
old_gen_growth_time_ratio: 3 (The desired maximum percentage of time spent in old gen GC)
old_gen_heap_size: 1024 (Max size of old gen heap size in MB,e.g: --old_gen_heap_size=1024 allows up to 1024MB old gen heap)
optimization_counter_scale: 2000 (The scale of invocation count, by size of the function.)
optimization_counter_threshold: 30000 (Function's usage-counter value before it is optimized, -1 means never)
optimization_filter: (null) (Optimize only named function)
overlap_type_arguments: true (When possible, partially or fully overlap the type arguments of a type with the type arguments of its super type.)
pause_isolates_on_exit: false (Pause isolates exiting.)
pause_isolates_on_start: false (Pause isolates before starting.)
pretenure_all: false (Global pretenuring (for testing).)
pretenure_interval: 10 (Back off pretenuring after this many cycles.)
pretenure_threshold: 98 (Trigger pretenuring when this many percent are promoted.)
print_ast: false (Print abstract syntax tree.)
print_class_table: false (Print initial class table.)
print_classes: false (Prints details about loaded classes.)
print_environments: false (Print SSA environments.)
print_flags: true (Print flags as they are being parsed.)
print_flow_graph: false (Print the IR flow graph.)
print_flow_graph_optimized: false (Print the IR flow graph when optimizing.)
print_free_list_after_gc: false (Print free list statistics after a GC)
print_free_list_before_gc: false (Print free list statistics before a GC)
print_ic_data_map: false (Print the deopt-id to ICData map in optimizing compiler.)
print_inlining_tree: false (Print inlining tree)
print_scopes: false (Print scopes of local variables.)
print_ssa_liveness: false (Print liveness for ssa variables.)
print_ssa_liveranges: false (Print live ranges after allocation.)
print_stacktrace_at_throw: false (Prints a stack trace everytime a throw occurs.)
print_stop_message: true (Print stop message.)
print_tokens: false (Print scanned tokens.)
profile: true (Enable Sampling Profiler)
profile_depth: 8 (Maximum number stack frames walked. Minimum 1. Maximum 255.)
profile_dir: (null) (Enable writing profile data into specified directory.)
profile_period: 1000 (Time between profiler samples in microseconds. Minimum 50.)
profile_vm: false (Always collect native stack traces.)
propagate_ic_data: true (Propagate IC data from unoptimized to optimized IC calls.)
prune_dead_locals: true (optimize dead locals away)
random_seed: 0 (Override the random seed for debugging.)
range_analysis: true (Enable range analysis)
remove_redundant_phis: true (Remove redundant phis.)
reoptimization_counter_threshold: 4000 (Counter threshold before a function gets reoptimized.)
reorder_basic_blocks: true (Enable basic-block reordering.)
show_internal_names: false (Show names of internal classes (e.g. "OneByteString") in error messages instead of showing the corresponding interface names (e.g. "String"))
show_invisible_frames: false (Show invisible frames in debugger stack traces)
silent_warnings: false (Silence warnings.)
source_lines: false (Emit source line as assembly comment.)
stacktrace_depth_on_warning: 5 (Maximal number of stack frames to print after a runtime warning.)
stacktrace_every: 0 (Compute debugger stacktrace on every N stack overflow checks)
stacktrace_filter: (null) (Compute stacktrace in named function on stack overflow checks)
stop_on_excessive_deoptimization: false (Debugging: stops program if deoptimizing same function too often)
throw_on_javascript_int_overflow: false (Throw an exception when the result of an integer calculation will not fit into a javascript integer.)
time_all: false (Time all functionality)
time_bootstrap: false (time_bootstrap)
time_compilation: false (time_compilation)
time_creating_snapshot: false (time_creating_snapshot)
time_dart_execution: false (time_dart_execution)
time_gc: false (time_gc)
time_isolate_initialization: false (time_isolate_initialization)
time_script_loading: false (time_script_loading)
time_total_runtime: false (time_total_runtime)
trace_api: false (Trace invocation of API calls (debug mode only))
trace_bailout: false (Print bailout from ssa compiler.)
trace_class_finalization: false (Trace class finalization.)
trace_compiler: false (Trace compiler operations.)
trace_constant_propagation: false (Print constant propagation and useless code elimination.)
trace_debugger_stacktrace: false (Trace debugger stacktrace collection)
trace_deoptimization: false (Trace deoptimization)
trace_deoptimization_verbose: false (Trace deoptimization verbose)
trace_disabling_optimized_code: false (Trace disabling optimized code.)
trace_failed_optimization_attempts: false (Traces all failed optimization attempts)
trace_field_guards: false (Trace changes in field's cids.)
trace_ic: false (Trace IC handling)
trace_ic_miss_in_optimized: false (Trace IC miss in optimized code)
trace_inlining: false (Trace inlining)
trace_integer_ir_selection: false (Print integer IR selection optimization pass.)
trace_intrinsified_natives: false (Report if any of the intrinsified natives are called)
trace_irregexp: false (Trace irregexps)
trace_isolates: false (Trace isolate creation and shut down.)
trace_load_optimization: false (Print live sets for load optimization pass.)
trace_natives: false (Trace invocation of natives (debug mode only))
trace_optimization: false (Print optimization details.)
trace_optimized_ic_calls: false (Trace IC calls in optimized code.)
trace_osr: false (Trace attempts at on-stack replacement.)
trace_parser: false (Trace parser operations.)
trace_patching: false (Trace patching of code.)
trace_profiled_isolates: false (Trace profiled isolates.)
trace_range_analysis: false (Trace range analysis progress)
trace_resolving: false (Trace resolving.)
trace_runtime_calls: false (Trace runtime calls)
trace_service: false (Trace VM service requests.)
trace_service_pause_events: false (Trace VM service isolate pause events.)
trace_ssa_allocator: false (Trace register allocation over SSA.)
trace_thread_interrupter: false (Trace thread interrupter)
trace_type_check_elimination: false (Trace type check elimination at compile time.)
trace_type_checks: false (Trace runtime type checks.)
trace_type_finalization: false (Trace type finalization.)
trace_type_propagation: false (Trace flow graph type propagation)
trap_on_deoptimization: false (Trap on deoptimization.)
truncating_left_shift: true (Optimize left shift to truncate if possible)
two_args_smi_icd: true (Generate special IC stubs for two args Smi operations)
unbox_mints: true (Optimize 64-bit integer arithmetic.)
unbox_numeric_fields: true (Support unboxed double and float32x4 fields.)
use_cha: true (Use class hierarchy analysis.)
use_field_guards: true (Guard field cids.)
use_inlining: true (Enable call-site inlining)
use_internal_hash_map: false (Use internal hash map.)
use_jscre: true (Use the JSCRE regular expression engine)
use_lib_cache: true (Use library name cache)
use_osr: true (Use on-stack replacement.)
use_slow_path: false (Set to true for debugging & verifying the slow paths.)
use_sse41: true (Use SSE 4.1 if available)
verbose_debug: false (Verbose debugger messages)
verbose_gc: false (Enables verbose GC.)
verbose_gc_hdr: 40 (Print verbose GC header interval.)
verbose_stacktrace: false (Stack traces will include methods marked invisible.)
verify_after_gc: false (Enables heap verification after GC.)
verify_before_gc: false (Enables heap verification before GC.)
verify_compiler: false (Enable compiler verification assertions)
verify_handles: false (Verify handles.)
verify_on_transition: false (Verify on dart <==> VM.)
warn_mixin_typedef: true (Warning on legacy mixin typedef.)
warn_on_javascript_compatibility: false (Warn on incompatibilities between vm and dart2js.)
warning_as_error: false (Treat warnings as errors.)
worker_timeout_millis: 5000 (Free workers when they have been idle for this amount of time.)
write_protect_code: true (Write protect jitted code)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment