[Mono-bugs] [Bug 76017][Min] New - Unnecessary allocations in System.Runtime.Serialization

bugzilla-daemon at bugzilla.ximian.com bugzilla-daemon at bugzilla.ximian.com
Thu Sep 8 20:25:16 EDT 2005

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 trow at ximian.com.


--- shadow/76017	2005-09-08 20:25:16.000000000 -0400
+++ shadow/76017.tmp.26755	2005-09-08 20:25:16.000000000 -0400
@@ -0,0 +1,27 @@
+Bug#: 76017
+Product: Mono: Class Libraries
+Version: 1.1
+OS Details: 
+Status: NEW   
+Priority: Minor
+Component: System
+AssignedTo: mono-bugs at ximian.com                            
+ReportedBy: trow at ximian.com               
+QAContact: mono-bugs at ximian.com
+TargetMilestone: ---
+Summary: Unnecessary allocations in System.Runtime.Serialization
+System.Runtime.Serialization.ObjectIDGenerator needs to maintain a
+Hashtable in which the keys are object instances.  To do this, it
+introduces an InstanceWrapper class which overrides Equals and GetHashCode,
+and uses those objects as the Hashtable keys.  However, this means that we
+have to allocate one of these objects for every Hashtable lookup.
+It would be much more efficient (and not any more difficult) to instead
+create a custom IComparer, passed in as an argument to the Hashtable's

More information about the mono-bugs mailing list