Skip to content

Build SOS interpreter test assets when enabled - #6015

Merged
max-charlamb merged 1 commit into
mainfrom
dev/max-charlamb/fix-sos-host-and-dual-runtime
Sep 9, 2026
Merged

max-charlamb merged 1 commit into
mainfrom
dev/max-charlamb/fix-sos-host-and-dual-runtime

Conversation

@max-charlamb

@max-charlamb max-charlamb commented Sep 9, 2026 •

Copy link
Copy Markdown
Member

Summary

Make -testInterpreter set SOS_TEST_INTERPRETER before the managed build as well as during test execution.

The runtime-diagnostics pipeline separates diagnostics build and test into different processes. Previously, -testInterpreter was passed only to the test invocation, so the tests were enabled but the interpreter debuggee projects had already been skipped during the build.

The companion runtime pipeline commit passes -testInterpreter to the diagnostics build step: dotnet/runtime@e3dc2ea6a39

This addresses the interpreter failures in: https://dev.azure.com/dnceng-public/public/_build/results?buildId=1587921

Validation

Removed the generated interpreter outputs and confirmed that a managed build with -testInterpreter recreated InterpreterStackTest, InterpreterStackInterleavedTest, and Trampoline for net11.0.

Note

This pull request description was generated with GitHub Copilot.

Copilot AI lite review requested due to automatic review settings September 9, 2026 13:49
@max-charlamb
max-charlamb requested a review from a team as a code owner September 9, 2026 13:49

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟢 Approval recommended

The changes are narrowly scoped to test harness/config behavior and the updated settings align with how the harness composes host+debuggee command lines and consumes DesktopRuntimePath.

Pull request overview

This PR fixes remaining SOS test harness failures in the runtime-diagnostics pipeline by ensuring interpreter-based debuggees run against the intended framework version, and by correctly switching SOS from cDAC to the legacy DAC when moving to the desktop (.NET Framework) runtime in the dual-runtime scenario.

Changes:

  • Launch framework-dependent debuggees via dotnet exec --fx-version ... on both Windows and Unix configurations.
  • Provide an explicit desktop runtime directory to SOS.DualRuntimes so setclrpath can load the correct legacy DAC.
  • Disable cDAC (runtimes --usecdac false) prior to selecting the desktop runtime in the dual-runtime script flow.
File summaries
File Description
src/tests/SOS.UnitTests/Scripts/DualRuntimes.script Forces legacy DAC before switching to desktop runtime and sets the desktop CLR path for correct desktop DAC loading.
src/tests/SOS.UnitTests/ConfigFiles/Windows/Debugger.Tests.Config.txt Passes the desktop runtime directory to the DualRuntimes test and updates host args to use dotnet exec --fx-version.
src/tests/SOS.UnitTests/ConfigFiles/Unix/Debugger.Tests.Config.txt Updates host args to use dotnet exec --fx-version for framework-dependent debuggees.
Review details
  • Files reviewed: 3/3 changed files
  • Comments generated: 0
  • Review effort level: Lite

💡 Add a code-review agent skill for context-aware, tailored reviews. Learn more in the docs.

@max-charlamb
max-charlamb marked this pull request as draft September 9, 2026 14:28
@max-charlamb max-charlamb changed the title Fix SOS interpreter and dual runtime tests Fix SOS interpreter build and cDAC fallback Sep 9, 2026
@max-charlamb
max-charlamb marked this pull request as ready for review September 9, 2026 15:48
@max-charlamb
max-charlamb requested a review from hoyosjs September 9, 2026 16:01
@max-charlamb max-charlamb reopened this Sep 9, 2026
@max-charlamb
max-charlamb force-pushed the dev/max-charlamb/fix-sos-host-and-dual-runtime branch from 6a09488 to 6febc4b Compare September 9, 2026 16:37
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

Copilot-Session: 7b2ca30d-742d-402c-8ba5-afec8b6d69a1
@max-charlamb
max-charlamb force-pushed the dev/max-charlamb/fix-sos-host-and-dual-runtime branch from 6febc4b to a1a6229 Compare September 9, 2026 17:02
@max-charlamb max-charlamb changed the title Fix SOS interpreter build and cDAC fallback Build SOS interpreter test assets when enabled Sep 9, 2026
@max-charlamb
max-charlamb enabled auto-merge (squash) September 9, 2026 18:06
@max-charlamb

Copy link
Copy Markdown
Member Author

/ba-g known flaky tests

@max-charlamb
max-charlamb merged commit aab0ab4 into main Sep 9, 2026
21 of 26 checks passed
@max-charlamb
max-charlamb deleted the dev/max-charlamb/fix-sos-host-and-dual-runtime branch September 9, 2026 18:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants