Skip to content

[reflection] Return n2m wrapper from RuntimeMethodHandle.GetFunctionPointer #60200

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Oct 11, 2021

Conversation

lambdageek
Copy link
Member

for functions marked with UnmanagedCallersOnlyAttribute, return a pointer to the n2m wrapper for calls to GetFunctionPointer

Contributes to #59815

@ghost
Copy link

ghost commented Oct 8, 2021

Tagging subscribers to this area: @BrzVlad
See info in area-owners.md if you want to be subscribed.

Issue Details

for functions marked with UnmanagedCallersOnlyAttribute, return a pointer to the n2m wrapper for calls to GetFunctionPointer

Contributes to #59815

Author: lambdageek
Assignees: -
Labels:

area-Codegen-Interpreter-mono

Milestone: -

@lambdageek
Copy link
Member Author

@BrzVlad can you take a look. In particular do we care about a (somewhat expensive) attribute check in MINT_LDFTN_DYNAMIC ?

…ointer

for functions marked with UnmanagedCallersOnlyAttribute, return a pointer to
the n2m wrapper for calls to GetFunctionPointer

Contributes to dotnet#59815
@lambdageek lambdageek force-pushed the fix-unmanaged-getfunctionpointer branch from 8c8647e to 4b725ec Compare October 9, 2021 17:20
@lambdageek lambdageek merged commit bda8727 into dotnet:main Oct 11, 2021
jkoritzinsky added a commit to jkoritzinsky/runtime that referenced this pull request Oct 11, 2021
Now that dotnet#59815 and dotnet#60200 are merged, the DllImportGenerator tests pass on Mono in desktop form factors (where hostfxr and hostpolicy exist).
@ghost ghost locked as resolved and limited conversation to collaborators Nov 10, 2021
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.

2 participants