.I nodebug
Instructs the AOT compiler to not output any debugging information.
.TP
+.I no-direct-calls
+This prevents the AOT compiler from generating a direct calls to a
+method. The AOT compiler usually generates direct calls for certain
+methods that do not require going through the PLT (for example,
+methods that are known to not require a hook like a static
+constructor) or call into simple internal calls.
+.TP
.I dwarfdebug
Instructs the AOT compiler to emit DWARF debugging information. When
used together with the nodebug option, only DWARF debugging
before using these flags for a deployment setting, you might want to
actually measure the benefits of using them.
.Sp
-The following optimizations are implemented:
+The following optimization flags are implemented in the core engine:
.nf
+ abcrem Array bound checks removal
all Turn on all optimizations
- peephole Peephole postpass
+ aot Usage of Ahead Of Time compiled code
branch Branch optimizations
- inline Inline method calls
cfold Constant folding
+ cmov Conditional moves [arch-dependency]
+ deadce Dead code elimination
consprop Constant propagation
copyprop Copy propagation
- deadce Dead code elimination
- linears Linear scan global reg allocation
- cmov Conditional moves [arch-dependency]
- shared Emit per-domain code
- sched Instruction scheduling
- intrins Intrinsic method implementations
- tailc Tail recursion and tail calls
- loop Loop related optimizations
fcmov Fast x86 FP compares [arch-dependency]
+ float32 Perform 32-bit float arithmetic using 32-bit operations
+ gshared Enable generic code sharing.
+ inline Inline method calls
+ intrins Intrinsic method implementations
+ linears Linear scan global reg allocation
leaf Leaf procedures optimizations
- aot Usage of Ahead Of Time compiled code
+ loop Loop related optimizations
+ peephole Peephole postpass
precomp Precompile all methods before executing Main
- abcrem Array bound checks removal
- ssapre SSA based Partial Redundancy Elimination
+ sched Instruction scheduling
+ shared Emit per-domain code
sse2 SSE2 instructions on x86 [arch-dependency]
- gshared Enable generic code sharing.
+ tailc Tail recursion and tail calls
.fi
.Sp
For example, to enable all the optimization but dead code
given option if used in combination with Ahead of Time compilation
(--aot flag) would produce pre-compiled code that will depend on the
current CPU and might not be safely moved to another computer.
+.RS
+.ne 8
+.PP
+The following optimizations are supported
+.TP
+.I float32
+Requests that the runtime performn 32-bit floating point operations
+using only 32-bits. By default the Mono runtime tries to use the
+highest precision available for floating point operations, but while
+this might render better results, the code might run slower. This
+options also affects the code generated by the LLVM backend.
+.TP
+.I inline
+Controls whether the runtime should attempt to inline (the default),
+or not inline methods invocations
+.ne
+.RE
.TP
\fB--runtime=VERSION\fR
Mono supports different runtime versions. The version used depends on the program
"cas" parameter.
.PP
The following modes are supported:
-.TP
-.I cas
-This allows mono to support declarative security attributes,
-e.g. execution of Code Access Security (CAS) or non-CAS demands.
.TP
.I core-clr
Enables the core-clr security system, typically used for
.TP
\fB(no-)lazy-sweep\fR
Enables or disables lazy sweep for the Mark&Sweep collector. If
-enabled, the sweep phase of the garbage collection is done piecemeal
-whenever the need arises, typically during nursery collections. Lazy
-sweeping is enabled by default.
+enabled, the sweeping of individual major heap blocks is done
+piecemeal whenever the need arises, typically during nursery
+collections. Lazy sweeping is enabled by default.
+.TP
+\fB(no-)concurrent-sweep\fR
+Enables or disables concurrent sweep for the Mark&Sweep collector. If
+enabled, the iteration of all major blocks to determine which ones can
+be freed and which ones have to be kept and swept, is done
+concurrently with the running program. Concurrent sweeping is enabled
+by default.
.TP
\fBstack-mark=\fImark-mode\fR
Specifies how application threads should be scanned. Options are
.RS
.ne 8
.TP
+\fBalign-small-structs\fR
+Enables small structs alignment to 4/8 bytes.
+.TP
+\fBarm-use-fallback-tls\fR
+When this option is set on ARM, a fallback TLS will be used instead
+of the default fast TLS.
+.TP
\fBbreak-on-unverified\fR
If this variable is set, when the Mono VM runs into a verification
problem, instead of throwing an exception it will break into the
InvalidCast exceptions, it will provide information about the types
involved.
.TP
+\fBcheck-pinvoke-callconv\fR
+This option causes the runtime to check for calling convention
+mismatches when using pinvoke, i.e. mixing cdecl/stdcall. It only
+works on windows. If a mismatch is detected, an
+ExecutionEngineException is thrown.
+.TP
\fBcollect-pagefault-stats\fR
Collects information about pagefaults. This is used internally to
track the number of page faults produced to load metadata. To display
this information you must use this option with "--stats" command line
option.
.TP
+\fBdebug-domain-unload\fR
+When this option is set, the runtime will invalidate the domain memory
+pool instead of destroying it.
+.TP
\fBdont-free-domains\fR
This is an Optimization for multi-AppDomain applications (most
commonly ASP.NET applications). Due to internal limitations Mono,
Instructs the runtime to try to use a generic runtime-invoke wrapper
instead of creating one invoke wrapper.
.TP
+\fBexplicit-null-checks\fR
+Makes the JIT generate an explicit NULL check on variable dereferences
+instead of depending on the operating system to raise a SIGSEGV or
+another form of trap event when an invalid memory location is
+accessed.
+.TP
\fBgdb\fR
Equivalent to setting the \fBMONO_XDEBUG\fR variable, this emits
symbols into a shared library as the code is JITed that can be loaded
IL stack is empty. These are places where the debugger can set a
breakpoint.
.TP
-\fBexplicit-null-checks\fR
-Makes the JIT generate an explicit NULL check on variable dereferences
-instead of depending on the operating system to raise a SIGSEGV or
-another form of trap event when an invalid memory location is
-accessed.
+\fBgen-compact-seq-points\fR
+This option generates sequence points data that maps native offsets to
+IL offsets. Sequence point data is used to display IL offset in
+stacktraces. Stacktraces with IL offsets can be symbolicated using
+mono-symbolicate tool.
.TP
\fBhandle-sigint\fR
Captures the interrupt signal (Control-C) and displays a stack trace
which will garbage collect the code. With this option it is possible
to track down the source of the problems.
.TP
+\fBno-gdb-backtrace\fR
+This option will disable the GDB backtrace emitted by the runtime
+after a SIGSEGV or SIGABRT in unmanaged code.
+.TP
+\fBpartial-sharing\fR
+When this option is set, the runtime can share generated code between
+generic types effectively reducing the amount of code generated.
+.TP
\fBreverse-pinvoke-exceptions
This option will cause mono to abort with a descriptive message when
during stack unwinding after an exception it reaches a native stack
undefined behaviour (since mono doesn't know how to process native
frames), leaks, and possibly crashes too.
.TP
-\fBno-gdb-backtrace\fR
-This option will disable the GDB backtrace emitted by the runtime
-after a SIGSEGV or SIGABRT in unmanaged code.
+\fBsingle-imm-size\fR
+This guarantees that each time managed code is compiled the same
+instructions and registers are used, regardless of the size of used
+values.
+.TP
+\fBsoft-breakpoints\fR
+This option allows using single-steps and breakpoints in hardware
+where we cannot do it with signals.
.TP
\fBsuspend-on-sigsegv\fR
This option will suspend the program when a native SIGSEGV is received.
This is useful for debugging crashes which do not happen under gdb,
since a live process contains more information than a core file.
.TP
-\fBcheck-pinvoke-callconv\fR
-This option causes the runtime to check for calling convention
-mismatches when using pinvoke, i.e. mixing cdecl/stdcall. It only
-works on windows. If a mismatch is detected, an
-ExecutionEngineException is thrown.
+\fBsuspend-on-exception\fR
+This option will suspend the program when an exception occurs.
+.TP
+\fBsuspend-on-unhandled\fR
+This option will suspend the program when an unhadled exception occurs.
.ne
.RE
.TP