[Mono-devel-list] [Patch] Manged code is fast!

Paolo Molaro lupus at ximian.com
Mon May 24 06:52:21 EDT 2004


On 05/21/04 Andreas Nahr wrote:
> Here are some microbenchmark results updated with the new figures (the last
> ones):
> CopyTo (002): 7190 -> 3595 -> 3645
> CopyTo (015): 7611 -> 4446 -> 4236
> CopyTo (016): 8982 -> 4486 -> 4186
> CopyTo (512): 3174 -> 2995 -> 2784
> 
> Also this means that it is now *ALWAYS* faster than managed (tested up to
> 512KB Strings).

Nice. Though as I think I said in the other mail, we need to use a
more generic method, like the memcpy I posted, so that it could be
implemented as asm if needed and so it could handle alignment issues:
your current code AFAIK will break the sparc port as sson as a copy is
made from an odd-numbered character offset.

> I also found that there seemed to be a bug (in the old original
> implementation) with Strings of Size 4MB and bigger.

Do you have details? Please share!

> I've also looked at your hashcode benchmark and added a version which
> resembles the patch that I had ready for this. First line is your Hash2
> impl, second is my Hash3 impl ;)
> Windows precompiled, X86 Athlon 2000XP:
> C:\Uni\NBen>mono hash-code-bench.exe

What are the results with -O=loop and -O=all? Using the loop
optimization is needed to make the jit produce fast code (I enabled it
by default on cvs).

lupus

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



More information about the Mono-devel-list mailing list