Skip to content

Conversation

@lambdageek
Copy link
Member

Instead of running the full mono_class_init_internal, just initialize
the supertypes and the interface bitmap.

Add a flag to mono_class_setup_interface_offsets to only publish the
interface bitmap, not the offsets.

Also move the SRE hack (setting a field in MonoClass to null and
running mono_class_setup_interface_offsets) to a new function
mono_class_invalidate_interface_offsets.

Also change the field that the SRE hack uses as a sentinel (used to be
MonoClass:interfaces_packed, now MonoClass:interface_offsets_packed)

Fixes #68033

Instead of running the full mono_class_init_internal, just initialize
the supertypes and the interface bitmap.

Add a flag to mono_class_setup_interface_offsets to only publish the
interface bitmap, not the offsets.

Also move the SRE hack (setting a field in MonoClass to null and
running mono_class_setup_interface_offsets) to a new function
mono_class_invalidate_interface_offsets.

Also change the field that the SRE hack uses as a sentinel (used to be
MonoClass:interfaces_packed, now MonoClass:interface_offsets_packed)

Fixes dotnet#68033
@ghost ghost added the area-VM-meta-mono label Aug 11, 2022
@ghost ghost assigned lambdageek Aug 11, 2022
@lambdageek

This comment was marked as outdated.

@lambdageek lambdageek marked this pull request as ready for review August 12, 2022 20:02
@lambdageek lambdageek requested a review from BrzVlad August 12, 2022 20:12
@lambdageek lambdageek added this to the 7.0.0 milestone Aug 12, 2022
@lambdageek
Copy link
Member Author

/azp run runtime-extra-platforms

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

Copy link
Member

@thaystg thaystg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@lambdageek lambdageek merged commit cf26421 into dotnet:main Aug 13, 2022
@ghost ghost locked as resolved and limited conversation to collaborators Sep 13, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Mono] TypeLoadException for class with variant interfaces

2 participants