[Mono-devel-list] New tracing functionality.

Paolo Molaro lupus at ximian.com
Mon Oct 13 11:34:42 EDT 2003


On 10/12/03 Miguel de Icaza wrote:
>    My objective was to make the command line tracing facility useful,
> that is why I decided to not use XML to describe the traces, nor to load
> the information from a file.  That can be added later if someone wants
> it very badly.
> 
>    By default mono --trace will continue to work like it used to do
> before.  If you use --trace=EXPRESSION then the new behavior kicks-in.
> 
>    The syntax is:
> 
> 		mono --trace=expr1[,expr2[,exprN]]

The cmdline interface is OK, but I would prefer the code to go into a
profiler module, so that libmono is not bloated (--trace is just a
temporary workaround for the lack of a debugger, anyway).
You can add a MONO_PROFILER_TRACE item to the MonoProfileFlags enum in
profiler.h. Then, in the module, you register a callback for
MONO_PROFILE_JIT_COMPILATION and if the passed method matches your
tracing rules, you set MONO_PROFILER_TRACE in the default profiling
options. The code in mini/* will check for this option (in
cfg->prof_options) instead of the current global symbol or instead of
making the call as in your patch.

> +Usability
> +---------
> +
> +* Remove the various optimization list of flags description, have an 
> +  extra --help-optimizations flag.
> +
> +* Remove the various graph options, have a separate --help-graph for 
> +  that list.

I wouldn't add --help-foo options. Maybe we can show the full info with
	mono -v --help (or --verbose)
instead.

lupus

-- 
-----------------------------------------------------------------
lupus at debian.org                                     debian/rules
lupus at ximian.com                             Monkeys do it better



More information about the Mono-devel-list mailing list