-
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
Release CordbUnmanagedThread
instance from CordbProcess
member
#66910
Release CordbUnmanagedThread
instance from CordbProcess
member
#66910
Conversation
The m_lastDispatchedIBEvent was not be cleared during shutdown, which was causing a memory leak assert to fire.
Co-authored-by: Adeel Mujahid <3840695+am11@users.noreply.github.com>
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.
Feels pretty safe - this is a flush, shutdown, or detach path. Might not mimic the best lifetime for the event being held but can't think of a better place to have it - you need it for other continue events and native event convoys. I couldn't find a case that wouldn't fall in this scenario as long as the debugger impl is checking the shutdown/detach path for interop.
…otnet#66910) * Release CordbUnmanagedThread from CordbProcess member The m_lastDispatchedIBEvent was not being cleared during shutdown, which was causing a memory leak assert to fire. Co-authored-by: Adeel Mujahid <3840695+am11@users.noreply.github.com>
…otnet#66910) * Release CordbUnmanagedThread from CordbProcess member The m_lastDispatchedIBEvent was not being cleared during shutdown, which was causing a memory leak assert to fire. Co-authored-by: Adeel Mujahid <3840695+am11@users.noreply.github.com>
…otnet#66910) * Release CordbUnmanagedThread from CordbProcess member The m_lastDispatchedIBEvent was not being cleared during shutdown, which was causing a memory leak assert to fire. Co-authored-by: Adeel Mujahid <3840695+am11@users.noreply.github.com>
Fixes #65357
The
m_lastDispatchedIBEvent
was not being cleared during shutdown, which was causing a memory leak assert to fire.See
runtime/src/coreclr/debug/di/process.cpp
Lines 8130 to 8148 in c3fa765
I added the clearing in the
NeuterChildren()
method because it seemed like the best place. Suggestions on more appropriate places is welcome./cc @dotnet/dotnet-diag