[Mono-dev] Question about JIT performance

Michael Hutchinson m.j.hutchinson at gmail.com
Thu Aug 14 03:36:12 EDT 2008


2008/8/14 Bojan Rajkovic <bojanr at brandeis.edu>:
<snip>
> The thing that immediately struck me as odd was: how is the inlined
> BoxApproximation that HAS a switch() call to check whether it's doing
> left, right or midpoint faster than everything else. It's not just a
> little faster, it's a lot faster. The machine running all of these tests
> is running Mono trunk as of a few days ago, x86 processor with a 2.0 GHz
> clock speed and 512 MB of RAM (it's a VMware server virtual machine).
> Running the same thing on Mono 1.9.1 outside of VMware yields similar
> results.

What intrigued me in our discussion is that on .NET, there is very
little difference between the four methods.  The only statistically
significant difference I could measure is that the inlined versions
are about 3-4% slower than the versions with the method call -- which
is in itself interesting. (For reference, it's about 21 cycles per
loop iteration on a Core 2 in 64-bit mode.)

-- 
Michael Hutchinson
http://mjhutchinson.com


More information about the Mono-devel-list mailing list