Repository navigation
Conversation
Prioritize .NET 10, then 11, 9, 8, and 12 when selecting a runtime to host SOS managed extensions. Define the framework assembly overrides shared by the native host and tests. Include System.Diagnostics.DiagnosticSource and System.IO.Pipelines based on their shared-framework introduction, and validate the native SOS layout against every configured host runtime so new version conflicts fail CI. Co-authored-by: Copilot App <[email protected]> Copilot-Session: 24deab87-ef2a-4528-9796-4890dc51785a
Contributor
There was a problem hiding this comment.
🟡 Changes recommended
Two moderate findings remain regarding runtime-selection coverage and validation of every configured runtime.
Get a fresh assessment by requesting another Copilot review.
Pull request overview
This PR updates SOS managed hosting runtime selection and centralizes framework assembly overrides for the native host and tests.
Changes:
- Prioritizes .NET 10, 11, 9, 8, then 12.
- Shares framework assembly override definitions.
- Adds SOS layout/runtime compatibility validation.
File summaries
| File | Summary |
|---|---|
src/tests/SOS.UnitTests/SOSHostRuntimeTests.cs |
Validates layout assemblies against host runtimes. Moderate finding: cover each non-single-file configuration instead of grouping by major (3 votes). |
src/tests/SOS.UnitTests/SOS.UnitTests.csproj |
Embeds shared assembly override metadata for tests. |
src/SOS/extensions/hostruntimeassemblylist.inc |
Defines shared framework assembly compatibility ranges. |
src/SOS/extensions/hostcoreclr.cpp |
Updates runtime probing and assembly overrides. Moderate finding: add a test confirming .NET 10 is selected before the other supported runtimes (1 vote). |
Review details
Suppressed comments (1)
src/SOS/extensions/hostcoreclr.cpp:75
- This changes the production runtime-probing precedence, but the added test only validates TPA override metadata; it never asserts which runtime
InitializeHostingselects. A regression in this array's order could therefore pass CI, so add a focused integration/unit test that makes multiple supported runtimes available and checks that 10 is selected before 11/9/8/12.
constexpr RuntimeVersion SupportedHostRuntimeVersions[] = {
{10, 0},
{11, 0},
{9, 0},
{8, 0},
- Files reviewed: 4/4 changed files
- Comments generated: 1
- Review effort level: Lite
💡 Add a code-review agent skill for context-aware, tailored reviews. Learn more in the docs.
steveisok
approved these changes
Sep 14, 2026
Validate every configured non-single-file host runtime and keep the production probing order in shared data covered by a focused test. Co-authored-by: Copilot App <[email protected]> Copilot-Session: 24deab87-ef2a-4528-9796-4890dc51785a
Enumerate the runtime configurations generated for the test environment instead of duplicating the production supported-runtime list in test data. Co-authored-by: Copilot App <[email protected]> Copilot-Session: 24deab87-ef2a-4528-9796-4890dc51785a
max-charlamb
pushed a commit
that referenced
this pull request
Sep 16, 2026
Combine the host-runtime probing and TPA override fixes from #6030 with target-framework-specific managed SOS payloads. Desktop CLR loads `net462`, while CoreCLR 8-12 loads `net8.0` and the host selects packaged framework assemblies only when the installed runtime is too old to satisfy them. The split is required for the overrides to be safe: CoreCLR 8 and 9 now receive DiagnosticSource 10 and Pipelines from the SDK-selected `lib/net8.0` assets instead of their `netstandard2.0` implementations. Packaging preserves both payloads under `lib/<tfm>` and fails when either payload is missing. There are no command or public API breaking changes; the internal SOS package layout now includes target-framework subdirectories. Manually verified HTTP symbol download with the final override payload on .NET 8.0.29 and .NET 9.0.18. The focused host-runtime override tests pass for all four configured runtimes. --------- Co-authored-by: Copilot App <[email protected]> Copilot-Session: a92a6889-a841-40da-8516-669fdc594b6f Copilot-Session: 24deab87-ef2a-4528-9796-4890dc51785a Copilot-Session: 58910d4b-200b-4437-a5bc-d02cfb42bc20
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.
Prioritize .NET 10, then 11, 9, 8, and 12 when selecting a runtime to host SOS managed extensions.
Define the framework assembly overrides shared by the native host and tests. Include System.Diagnostics.DiagnosticSource and System.IO.Pipelines based on their shared-framework introduction, and validate the native SOS layout against every configured host runtime so new version conflicts fail CI.