[Mono-bugs] [Bug 506144] New: Structs that contain Mono.Simd.Vector4f fields have broken sequential layout

bugzilla_noreply at novell.com bugzilla_noreply at novell.com
Thu May 21 16:05:07 EDT 2009


http://bugzilla.novell.com/show_bug.cgi?id=506144


           Summary: Structs that contain Mono.Simd.Vector4f fields have
                    broken sequential layout
    Classification: Mono
           Product: Mono: Runtime
           Version: SVN
          Platform: i686
        OS/Version: Windows Vista
            Status: NEW
          Severity: Normal
          Priority: P5 - None
         Component: JIT
        AssignedTo: lupus at novell.com
        ReportedBy: mhutchinson at novell.com
         QAContact: mono-bugs at lists.ximian.com
                CC: miguel at novell.com
          Found By: ---


Created an attachment (id=293732)
 --> (http://bugzilla.novell.com/attachment.cgi?id=293732)
Test case for the layout issue.

I have a struct that contains four Mono.Simd.Vector4f fields. I'm using it as a
pointer into unmanaged code.

[StructLayout (LayoutKind.Sequential)]
struct Matrix {
    public Vector4f col0, col1, col2, col3;
}

The problem is that on Mono, the address of the first field is not the same as
the address of the struct, despite using LayoutKind.Sequential. This means that
code that works on .NET does not work on Mono.

A test case is attached.

-- 
Configure bugmail: http://bugzilla.novell.com/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.


More information about the mono-bugs mailing list