[Mono-bugs] [Bug 74014][Nor] New - Method BitConverter.ToString() runs very very slow (possible string concatention bug)

bugzilla-daemon@bugzilla.ximian.com bugzilla-daemon@bugzilla.ximian.com
Wed, 23 Mar 2005 09:20:49 -0500 (EST)


Please do not reply to this email- if you want to comment on the bug, go to the
URL shown below and enter your comments there.

Changed by dezelin@gmail.com.

http://bugzilla.ximian.com/show_bug.cgi?id=74014

--- shadow/74014	2005-03-23 09:20:49.000000000 -0500
+++ shadow/74014.tmp.24442	2005-03-23 09:20:49.000000000 -0500
@@ -0,0 +1,60 @@
+Bug#: 74014
+Product: Mono: Class Libraries
+Version: 1.0
+OS: 
+OS Details: 
+Status: NEW   
+Resolution: 
+Severity: 
+Priority: Normal
+Component: CORLIB
+AssignedTo: mono-bugs@ximian.com                            
+ReportedBy: dezelin@gmail.com               
+QAContact: mono-bugs@ximian.com
+TargetMilestone: ---
+URL: 
+Cc: 
+Summary: Method BitConverter.ToString() runs very very slow (possible string concatention bug)
+
+Description of Problem:
+
+Method BitConverter.ToString() is very slow for big data conversions (150Kb
+> 30 min) due to uses of the operator = for string concatentions. I've
+implemented this faster (~ times). Patch is in the attachment.
+
+With this patch applied:
+
+maverick@maverick0:~/Documents/Work/c#/testcase-bitconverter-tostring/bin$
+time mono --debug test-bitconverter-tostring.exe
+
+real    0m0.074s
+user    0m0.040s
+sys     0m0.019s
+
+Without this patch:
+
+~s
+
+Is this just a workaround for the string concatention method in corlib?
+
+Cheers,
+Aleksandar Dezelin
+
+
+
+
+
+Steps to reproduce the problem:
+1. Try to run the supplied testcase. 
+
+Actual Results:
+Very Very Very slow execution.
+
+Expected Results:
+~ times faster execution
+
+How often does this happen? 
+Always
+
+Additional Information:
+See the attachment for the testcase and a patch.