[Mono-list] Profiling

David Sheldon dave-monolist@earth.li
Tue, 9 Dec 2003 23:04:09 +0000


On Tue, Dec 09, 2003 at 02:24:30PM -0500, Miguel de Icaza wrote:
> Hello,
> 
> > I see several mentions of a mono profiler. Is this just mint --profile,
> > or is there an interface to it/something that tells you where all the
> > objects have been created?
> 
> If you are using `mint', you are missing on all the performance.  That
> is a very slow interpreter, you should be using `mono', which is our
> super-cool, high-performance JIT compiler.
> 
> But yes, the profiler is --profile.

I had missed the --profile option on the mono help. Anyway, I think I am
trying to use the profiler for the wrong sort of thing. The test code I
ran was so short that it was faster in mint than mono anyway (about
170ms rather than 260ms). When I actually care about performance I might
look into how one should go about it.

Incidently is there a list of stupid things that you shouldn't do for
performance? Or some rules for which operations are expensive? How does 
"is" compare in speed to actually calling a virtual method on the type
for example, or should I go and experiment for myself? Basically I don't
want to be writing big slow code just because I don't understand C# as
much as I do C or similar.

David
-- 
Hanlon's Razor:
	Never attribute to malice that which is adequately explained
	by stupidity.