[Mono-dev] [PATCH] String.cs

Phil Garcia phil at thinkedge.com
Wed May 6 12:01:44 EDT 2009


Yes, I have performed some benchmark testing. Attached is a copy of the
benchmark program. It's runs most of the existing test cases for the Split
method in a loop a million times.

The results between the managed and unmanaged versions are statistically the
same. The unmanaged version seems to be slightly faster by 1.4%. The
unmanaged version was never faster than the managed version in all the
benchmark runs.

I only have an ESXi virtual environment (running only two guests) to run the
benchmark so my sampling error is higher than if tested on a dedicated
machine. I would appreciate some independent verification, if necessary.

Phil
(aka tgiphil on #monodev)

On Wed, May 6, 2009 at 6:35 AM, Rafael Teixeira <monoman at gmail.com> wrote:

> Do you have some benchmarks comparing the two versions? Although we really
> like the idea of having less-and-less unmanaged code in the system class
> libraries, we need to be sure the solution does not affect performance too
> badly.
>
> Thanks for your efforts so far,
>
>   On Wed, May 6, 2009 at 7:03 AM, Phil <mono at thinkedge.com> wrote:
>
>>   Hi! This is my first submission to Mono.
>>
>> The attached patch replaces the unmanaged version of the
>> String.InternalSplit() method with a managed implementation. This is a
>> direct port from the existing C code to C#. I tested this against the 2.0
>> and 1.1 profiles and there were no regressions. This patch is contributed
>> under the X11 license.
>>
>> I hope it can be incorporated into Mono.
>>
>> Phil
>>
>> BTW. This is the first patch submission from the MOSA Project team.
>>
>>
>> _______________________________________________
>> Mono-devel-list mailing list
>> Mono-devel-list at lists.ximian.com
>> http://lists.ximian.com/mailman/listinfo/mono-devel-list
>>
>>
>
>
> --
> Rafael "Monoman" Teixeira
> ---------------------------------------
> "To be creative means to be in love with life. You can be creative only if
> you love life enough that you want to enhance its beauty, you want to bring
> a little more music to it, a little more poetry to it, a little more dance
> to it."
> Osho
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.ximian.com/pipermail/mono-devel-list/attachments/20090506/df429fb8/attachment.html 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Test.cs
Type: application/octet-stream
Size: 2708 bytes
Desc: not available
Url : http://lists.ximian.com/pipermail/mono-devel-list/attachments/20090506/df429fb8/attachment.obj 


More information about the Mono-devel-list mailing list