Skip to content

Mono does not align Int128 types on correct boundaries when p/invoking or passing pointers to them to unmanaged code #74223

@davidwrighton

Description

@davidwrighton

Description

Mono does not align Int128 types on correct boundaries when p/invoking or passing pointers to them to unmanaged code.

As of PR #74123 the layout of Int128 in CoreCLR and NativeAOT will match the native platform Int128 types.

Reproduction Steps

Enable the $(XunitTestBinBase)/Interop/PInvoke/Int128/Int128TestFieldLayout test and run it.

Expected behavior

Test should pass

Actual behavior

Test fails

Regression?

No, Int128 is a new type for .NET 7

Known Workarounds

Architecture specific tricks to align them correctly.

Configuration

No response

Other information

No response

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions