Abstract away debug read/write channel.#123196
Merged
AaronRobinsonMSFT merged 4 commits intodotnet:mainfrom Jan 23, 2026
Merged
Abstract away debug read/write channel.#123196AaronRobinsonMSFT merged 4 commits intodotnet:mainfrom
AaronRobinsonMSFT merged 4 commits intodotnet:mainfrom
Conversation
Member
Author
|
/cc @dotnet/dotnet-diag |
Contributor
|
Tagging subscribers to this area: @steveisok, @tommcdon, @dotnet/dotnet-diag |
noahfalk
reviewed
Jan 17, 2026
Member
noahfalk
left a comment
There was a problem hiding this comment.
A few suggestions inline, but this looks nice to me. Thanks @AaronRobinsonMSFT!
Contributor
There was a problem hiding this comment.
Pull request overview
This pull request refactors the debug transport layer by introducing an IDebugChannel COM interface to abstract the communication channel previously implemented directly with TwoWayPipe. This abstraction enables cleaner separation of concerns and potentially allows for different transport implementations in the future.
Changes:
- Introduced
IDebugChannelinterface with methods for connection management and read/write operations - Refactored
DbgTransportSessionto useIDebugChannel*instead of directTwoWayPipeusage - Implemented
DbgTransportPipeChannelas a COM wrapper aroundTwoWayPipe - Created
DebuggerStartUphelper class to encapsulate startup notification logic - Fixed header guard naming in
processdescriptor.hto match the file name - Made
InitIPCEventpublic to support the newDebuggerStartUpabstraction - Unified
CleanupTargetProcess()across all platforms in the native pipeline
Reviewed changes
Copilot reviewed 9 out of 9 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| src/coreclr/debug/shared/dbgtransportsession.cpp | Main implementation of IDebugChannel abstraction, including DbgTransportPipeChannel wrapper class and updated session management |
| src/coreclr/debug/inc/dbgtransportsession.h | IDebugChannel interface definition, replaced TwoWayPipe member with IDebugChannel pointer, moved statistics block |
| src/coreclr/debug/inc/processdescriptor.h | Fixed header guard naming from _PROCESSCONTEXT_H to PROCESSDESCRIPTOR_H |
| src/coreclr/debug/ee/debugger.h | Made InitIPCEvent public and removed RaiseStartupNotification declaration |
| src/coreclr/debug/ee/debugger.cpp | Introduced DebuggerStartUp class to encapsulate startup logic, moved RaiseStartupNotification implementation |
| src/coreclr/debug/di/windowspipeline.cpp | Added CleanupTargetProcess() no-op implementation for Windows |
| src/coreclr/debug/di/process.cpp | Fixed typo in comment, updated documentation, removed platform-specific ifdef |
| src/coreclr/debug/di/nativepipeline.h | Made CleanupTargetProcess() a pure virtual method for all platforms |
| src/coreclr/debug/di/dbgtransportpipeline.cpp | Removed platform-specific ifdef around CleanupTargetProcess() |
noahfalk
approved these changes
Jan 22, 2026
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.