diff options
author | Jan Vorlicek <janvorli@microsoft.com> | 2018-08-23 02:42:43 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-08-23 02:42:43 +0200 |
commit | 8cd4b39a42c1c7cf37502357e6a4cb2888f5dfd7 (patch) | |
tree | a767facb00becfc9b6b9f0c3a8d731e566e3d1c3 /src/pal | |
parent | 8013a4b6786d9e6618f8ed36bd0a473aa17b72aa (diff) | |
download | coreclr-8cd4b39a42c1c7cf37502357e6a4cb2888f5dfd7.tar.gz coreclr-8cd4b39a42c1c7cf37502357e6a4cb2888f5dfd7.tar.bz2 coreclr-8cd4b39a42c1c7cf37502357e6a4cb2888f5dfd7.zip |
Enable unloading of AssemblyLoadContext (#18476)
Enable assembly unloading
* Allow PInvoke methods on collectible assemblies
* Fix test unloadability
Several hundreds of tests were using Helper class that created
GCHandle, but never freed it. That prevented unloading of those
tests. The change modifies the Helper class to keep the handle
in a finalizable object.
Several GCHandle related tests were not freeing the GCHandle they
allocated, so this change adds freeing them to enable the unloading.
* Add missing error messages to the resources
* Fix shuffle thunk cache for unloadability
* Add GetLoaderAllocator to ICLRPrivBinder
Diffstat (limited to 'src/pal')
-rw-r--r-- | src/pal/prebuilt/inc/clrprivbinding.h | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/pal/prebuilt/inc/clrprivbinding.h b/src/pal/prebuilt/inc/clrprivbinding.h index 4d3d36d05f..04ef10c3f6 100644 --- a/src/pal/prebuilt/inc/clrprivbinding.h +++ b/src/pal/prebuilt/inc/clrprivbinding.h @@ -171,7 +171,9 @@ EXTERN_C const IID IID_ICLRPrivBinder; /* [in] */ LPVOID pvAssemblySpec, /* [out] */ HRESULT *pResult, /* [out] */ ICLRPrivAssembly **ppAssembly) = 0; - + + virtual HRESULT STDMETHODCALLTYPE GetLoaderAllocator( + /* [retval][out] */ LPVOID* pLoaderAllocator) = 0; }; @@ -219,6 +221,10 @@ EXTERN_C const IID IID_ICLRPrivBinder; /* [out] */ HRESULT *pResult, /* [out] */ ICLRPrivAssembly **ppAssembly); + HRESULT(STDMETHODCALLTYPE *GetLoaderAllocator)( + ICLRPrivBinder * This, + /* [retval][out] */ LPVOID *pLoaderAllocator) = 0; + END_INTERFACE } ICLRPrivBinderVtbl; |