[Mono-bugs] [Bug 24003] New - GetHashCode() hack makes fields misaligned

bugzilla-daemon@rocky.ximian.com bugzilla-daemon@rocky.ximian.com
29 Apr 2002 16:15:07 -0000

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 lupus@ximian.com.


--- shadow/24003	Mon Apr 29 12:15:07 2002
+++ shadow/24003.tmp.4802	Mon Apr 29 12:15:07 2002
@@ -0,0 +1,24 @@
+Bug#: 24003
+Product: Mono/Runtime
+Version: unspecified
+OS: other
+OS Details: 
+Status: NEW   
+Priority: Normal
+Component: misc
+AssignedTo: mono-bugs@ximian.com                            
+ReportedBy: lupus@ximian.com               
+QAContact: mono-bugs@ximian.com
+TargetMilestone: ---
+Summary: GetHashCode() hack makes fields misaligned
+The GetHashCode hack that put the hash code at the beginning of the memory
+returned by malloc() causes misalignment of the fields: this makes
+platforms that require aligned access to doubles and int64 integers to segfault
+(malloc and GC_malloc return 8-byte aligned memory in that cases: the
+additional 4 bytes causes the misalignment). The hash code should either be
+stored at the end of the object or the hack should be removed.