Skip to content

Remove empty finalizers from bridge objects #12303

Description

@BrzVlad

Mono required bridge objects to have a finalizer so that they can be iterated during GC. For CoreCLR we use a completely different mechanism, by having explicit gc handles registered for all these objects. This means that, for CoreCLR, finalizers just add unnecessary overhead. I believe we should be able to remove them once mono support is dropped from this repository, probably for .net12.

Example: https://github.com/dotnet/android/blob/main/src/Mono.Android/Java.Lang/Object.cs#L32

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions