3 .\" (C) 2003 Ximian, Inc.
5 .\" Miguel de Icaza (miguel@gnu.org)
7 .de Sp \" Vertical space (when we can't use .PP)
13 mono \- Mono's code ECMA-CLI code generator (Just-in-Time and Ahead-of-Time)
16 .B mono [options] file [arguments...]
18 \fImono\fP is a runtime implementation of the ECMA Common Language
19 Infrastructure. This can be used to run ECMA and .NET applications.
21 The runtime contains a native code generator that transforms the
22 Common Intermediate Language into native code.
24 The code generator can operate in two modes: just in time compilation
25 (JIT) or ahead of time compilation (AOT). Since code can be
26 dynamically loaded, the runtime environment and the JIT are always
27 present, even if code is compiled ahead of time.
29 The runtime loads ths specified
36 is an ECMA assembly. They typically have a .exe or .dll extension.
38 The runtime provides a number of configuration options for running
39 applications, for developping and debugging, and for testing and
40 debugging the runtime itself.
42 The following options are available:
45 This option is used to precompile the CIL code in the specified
46 assembly to native code. The generated code is stored in a file with
47 the extension .so. This file will be automatically picked up by the
48 runtime when the assembly is executed.
50 This pre-compiles the methods, but the original assembly is still
51 required to execute as this one contains the metadata and exception
52 information which is not availble on the generated file. When
53 precompiling code, you might want to compile with all optimizations
54 (-O=all). Pre-compiled code is position independent code.
56 Pre compilation is just a mechanism to reduce startup time, and avoid
57 just-in-time compilation costs. The original assembly must still be
58 present, as the metadata is contained there.
60 .I "--config filename"
61 Load the specified configuration file instead of the default one(s).
62 The default files are /etc/mono/config and ~/.mono/config or the file
63 specified in the MONO_CONFIG environment variable, if set. See the
64 mono-config(5) man page for details on the format of this file.
67 Displays usage instructions.
69 .I "--optimize=MODE", "-O=mode"
70 MODE is a comma separated list of optimizations. They also allow
71 optimizations to be turned off by prefixing the optimization name with
74 The following optimizations are implemented:
76 all Turn on all optimizations
77 peephole Peephole postpass
78 branch Branch optimizations
79 inline Inline method calls
80 cfold Constant folding
81 consprop Constant propagation
82 copyprop Copy propagation
83 deadce Dead code elimination
84 linears Linear scan global reg allocation
85 cmov Conditional moves
86 shared Emit per-domain code
87 sched Instruction scheduling
88 intrins Intrinsic method implementations
89 tailc Tail recursion and tail calls
90 loop Loop related optimizations
93 For example, to enable all the optimization but dead code
94 elimination and inlining, you can use:
96 -O=all,-deadce,-inline
98 .SH DEVELOPMENT OPTIONS
101 Inserts a breakpoint before the method whose name is `method'
102 (namespace.class:methodname). Use `Main' as method name to insert a
103 breakpoint on the application's main method.
106 Inserts a breakpoint on exceptions. This allows you to debug your
107 application with a native debugger when an exception is thrown.
110 Performs coverage analysis on the underlying IL code.
113 Shows method names as they are invoked.
117 .SH DEVELOPMENT OPTIONS
118 The following options are used to debug a JITed application. They're
119 only useful when running the JIT in a debugger:
122 Turns on the debugging mode in the runtime. If an assembly was
123 compiled with debugging information, it will produce line number
124 information for stack traces.
127 Instructs the runtime to collect profiling information about execution
128 times and memory allocation, and dump it at the end of the execution.
132 .SH MAINTAINER OPTIONS
133 The maintainer options are only used by those developing the runtime
134 itself, and not typically of interest to runtime users or developers.
137 This compiles a method (namespace.name:methodname), this is used for
138 testing the compiler performance or to examine the output of the code
142 Compiles all the methods in an assembly. This is used to test the
143 compiler performance or to examine the output of the code generator
145 .I "--graph=TYPE METHOD"
146 This generates a postscript file with a graph with the details about
147 the specified method (namespace.name:methodname). This requires `dot'
148 and ghostview to be installed (it expects Ghostview to be called
151 The following graphs are available:
153 cfg Control Flow Graph (CFG)
155 code CFG showing code
156 ssa CFG showing code after SSA translation
157 optcode CFG showing code after IR optimizations
160 Some graphs will only be available if certain optimizations are turned
164 Instruct the runtime on the number of times that the method specified
165 by --compile (or all the methods if --compileall is used) to be
166 compiled. This is used for testing the code generator performance.
169 Increases the verbosity level, each time it is listed, increases the
170 verbosity level to include more information.
173 Prints JIT version information.
176 .SH ENVIRONMENT VARIABLES
179 Turns off the garbage collection in Mono. This should be only used
180 for debugging purposes
183 Provides a search path to the runtime where to look for library files.
184 Directories are separated by the platform path separator (colons on unix). Example:
185 .B /home/username/lib:/usr/local/mono/lib
187 .I "MONO_DISABLE_SHM"
188 If this variable is set, it disables the Windows I/O Emulation layer,
189 and handles (files, events, mutexes, pipes) will not be shared across
190 processes. This option is only available on Unix.
193 If set, this variable overrides the default system configuration directory
194 ($PREFIX/etc). It's used to locate machine.config file.
197 If set, this variable overrides the default runtime configuration file
198 ($PREFIX/etc/mono/config). The --config command line options overrides the
199 environment variable.
201 On Unix assemblies are loaded from the installation lib directory. If you set
202 `prefix' to /usr, the assemblies will be located in /usr/lib. On
203 Windows, the assemblies are loaded from the directory where mono and
206 /etc/mono/config, ~/.mono/config
208 Mono runtime configuration file. See the mono-config(5) manual page
209 for more information.
211 Visit http://mail.ximian.com/mailman/mono-list for details.
213 Visit: http://www.go-mono.com for details
215 .BR mcs(1), mint(1), monodis(1), mono-config(5)