-
Notifications
You must be signed in to change notification settings - Fork 4.7k
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
Clean up managed dependencies for Mono's domain/loader context #46323
Conversation
MonoObject *unload_lock; | ||
MonoEvent *resolving_unmaned_dll; | ||
MonoEvent *resolving; | ||
MonoEvent *unloading; | ||
MonoString *name; | ||
MonoAssemblyLoadContext *native_assembly_load_context; | ||
gint64 id; | ||
gint32 internal_state; | ||
MonoBoolean is_collectible; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@CoffeeFlux are any of these fields going to be necessary for future collectible ALC work?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good idea
- all the places where we use
MONO_STATIC_POINTER_INIT
need an additionalinited
flag now, so that we don't look for the method on every invocation when the pointer is allowed to be NULL - There are a few more uses of
mono_class_get_appdomain_class
etc that are visible that will break.mono_class_get_appdomain_class
is generated byGENERATE_GET_CLASS_WITH_CACHE
which will assert if the class isn't found. There's aGENERATE_TRY_GET_CLASS_WITH_CACHE_DECL
that makes a getter that can return null, but in this case I think it's just easier to put all the uses under an ifdef.
src/mono/netcore/System.Private.CoreLib/src/System/Runtime/Loader/AssemblyLoadContext.Mono.cs
Show resolved
Hide resolved
Co-authored-by: Aleksey Kliger (λgeek) <[email protected]>
Co-authored-by: Aleksey Kliger (λgeek) <[email protected]>
Co-authored-by: Aleksey Kliger (λgeek) <[email protected]>
Co-authored-by: Aleksey Kliger (λgeek) <[email protected]>
Co-authored-by: Aleksey Kliger (λgeek) <[email protected]>
Co-authored-by: Aleksey Kliger (λgeek) <[email protected]>
Co-authored-by: Aleksey Kliger (λgeek) <[email protected]>
Co-authored-by: Aleksey Kliger (λgeek) <[email protected]>
Co-authored-by: Aleksey Kliger (λgeek) <[email protected]>
src/mono/mono/mini/mini-runtime.c
Outdated
@@ -358,6 +358,7 @@ mono_print_method_from_ip (void *ip) | |||
*/ | |||
gboolean mono_method_same_domain (MonoJitInfo *caller, MonoJitInfo *callee) | |||
{ | |||
#ifndef ENABLE_NETCORE |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
(Same problem in #46346 ) this #ifndef
should be lower, before the line cmethod = jinfo_get_method (caller);
- we still want to return FALSE for trampolines and other edge cases
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, will wait for you to land that first and rebase this PR
07b3f44
to
044ccf5
Compare
This reverts commit 94e855e.
Follow up change missing in dotnet#46323 Fixes dotnet#46908
Follow up change missing in dotnet/runtime#46323 Fixes dotnet/runtime#46908
…0743) Follow up change missing in dotnet/runtime#46323 Fixes dotnet/runtime#46908 Co-authored-by: marek-safar <[email protected]>
No description provided.