You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Memory leaks when reverse P/Invoke is called from unmanaged thread #64509
changed the title [-]Memory leaks when reverse P/Invoke is called from unmanged thread.[/-][+]Memory leaks when reverse P/Invoke is called from unmanged thread[/+]on Jan 30, 2022
changed the title [-]Memory leaks when reverse P/Invoke is called from unmanged thread[/-][+]Memory leaks when reverse P/Invoke is called from unmanaged thread[/+]on Feb 7, 2022
ghost added
in-prThere is an active PR which will close this issue when it is merged
Activity
[-]Memory leaks when reverse P/Invoke is called from unmanged thread.[/-][+]Memory leaks when reverse P/Invoke is called from unmanged thread[/+]jkotas commentedon Jan 30, 2022
This looks like a regression introduced by #43423 . Potential duplicate of #60566.
@janvorli root caused it in #43423 (comment) .
We need to explicitly touch
tls_destructionMonitorwhen the new thread gets attached to the runtime, similar to how it is done in NativeAOTruntime/src/coreclr/nativeaot/Runtime/unix/PalRedhawkUnix.cpp
Line 479 in d4f06a9
@VSadov We will need to get a fix for this pushed to .NET 6 servicing. Could you please take care of it?
VSadov commentedon Jan 31, 2022
Will take a look. Yes, most likely touching
tls_destructionMonitorwill fix this.[-]Memory leaks when reverse P/Invoke is called from unmanged thread[/-][+]Memory leaks when reverse P/Invoke is called from unmanaged thread[/+]VSadov commentedon Mar 9, 2022
Fixed in #65406