Repository navigation
Move main desktop performance measurements to SDK 12 and net12.0 - #5344
LoopedBard3 merged 12 commits into
Conversation
Keep MAUI/mobile on net11 with SDK12 and preserve older channel runner versions. Add net12 framework, package, tooling and pipeline support with focused regression coverage. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
There was a problem hiding this comment.
🟡 Changes recommended
Unresolved SDK pinning and framework defaults break supported net11 and Mono WASM workflows, while SDK metadata and mixed-target runner selection remain incorrect.
4 open issues
What changed in this PR
Moves main-channel desktop performance measurements to SDK 12 and net12.0, with compatibility handling for older frameworks and mobile targets.
Changes:
- Updates SDK pins, framework defaults, scenario coverage, and tooling test targets.
- Adds a net12-specific BenchmarkDotNet runner, AOT filtering compatibility, and CoreCLR WASM selection.
- Separates SDK acquisition from target selection and adds regression tests and documentation.
| File | Description |
|---|---|
| src/tools/ResultsComparer/Data.cs | Recognizes net12 result paths. |
| src/tools/ResultsComparer.Tests/ResultsComparer.Tests.csproj | Targets net12. |
| src/tools/ResultsComparer.Tests/DataTests.cs | Tests extraction across framework versions. |
| src/tools/Reporting/Reporting.Tests/Reporting.Tests.csproj | Targets net12. |
| src/tests/harness/BenchmarkDotNet.Extensions.Tests/BenchmarkDotNet.Extensions.Tests.csproj | Tests the net12 runner and benchmarks. |
| src/tests/harness/BenchmarkDotNet.Extensions.Tests/AotFilterTests.cs | Tests runtime-specific AOT exclusions. |
| src/scenarios/build-common/Blazor.PackageVersions.props | Adds net12 Blazor package selection. |
| src/scenarios/build-common/Blazor.Directory.Build.targets | Advances the framework warning threshold. |
| src/harness/BenchmarkDotNet.Extensions/BenchmarkDotNet.Extensions.csproj | Adds conditional net12 runner dependencies. |
| src/harness/BenchmarkDotNet.Extensions/AotFilterAttribute.cs | Restores AOT exclusion support. |
| src/benchmarks/micro/README.md | Documents net12 execution and compatibility limits. |
| src/benchmarks/micro/MicroBenchmarks.csproj | Adds net12 support and runner selection. |
| src/benchmarks/micro/libraries/System.Runtime/Perf.Uri.cs | Strongly types URI argument sources. |
| src/benchmarks/micro/libraries/System.Net.Security/SslStreamTests.Protocols.cs | Strongly types TLS argument sources. |
| scripts/tests/test_channel_map.py | Adds channel, framework, and package-selection tests. |
| scripts/run_performance_job.py | Adds independent target selection and mobile fallback. |
| scripts/micro_benchmarks.py | Selects net12 CoreCLR WASM and rejects Mono WASM. |
| scripts/ci_setup.py | Adds framework overrides and net11 SDK pin handling. |
| scripts/channel_map.py | Maps main to SDK/runtime 12. |
| global.net11.json | Preserves the SDK 11 configuration. |
| global.json | Pins the root SDK to version 12. |
| eng/Versions.props | Defines the net12-specific BenchmarkDotNet version. |
| eng/pipelines/templates/runtime-perf-job.yml | Changes the default framework to net12. |
| eng/pipelines/sdk-perf-jobs.yml | Updates SDK installation and tooling test commands. |
| eng/performance/sdk_scenarios.proj | Adds net12 to SDK scenarios. |
| docs/scenarios-workflow.md | Documents desktop and mobile target selection. |
Review effort: Balanced
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
|
Follow-up on the two design questions, alongside 6dbc9d5/9c916affb:
The net12 WASM case is now after net11 and still passes the requested historical |
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
There was a problem hiding this comment.
🟡 Changes recommended
Critical net12/BDN649 compatibility gaps cause WASM argument parsing failures, prevent Mono AOT jobs from running, and make the R2R interpreter lane target net11 instead of net12.
6 open issues
Restore MonoAotLLVM compatibility before BDN649 · New Support legacy CoreCLR WASM runtime option · New R2R interpreter lane mixes net12 framework with net11 runtime Mono WASM jobs default to unsupported net12 target Fix mobile jobs for framework-specific Mono-WASM SDK setup Select runner per inner-build target framework
Review effort: Balanced
There was a problem hiding this comment.
🔵 Needs a closer look
The newer runner rejects unhandled legacy arguments in both native Mono-AOT and net12 CoreCLR WASM jobs, causing argument-parsing failures before benchmarks can run.
5 open issues
1 resolved since last review
Review effort: Balanced
|
Local candidate integration is now checked against the exact global641 commit plus migration head The composition removes the migration's595/649 split, runner property/reference propagation and duplicate compatibility, taking the prerequisite's typed async sources, LINQ10.0.9 and AOT/LLVM compatibility unchanged. The SDK-only delta is22files. Its saved patch was replayed against the candidate in an isolated Git index and reproduced the validated tree Windows x64, private SDK12.0.100-alpha.1.26527.106;
Real Program listing checks also accepted historical CoreCLR flavor and Mono12 arguments, while explicitly rejecting conflicting flavor/runtime inputs. Listing returns1 even for the no-runtime-option control because the existing empty-summary exit policy applies; this is parser evidence, not WASM execution. The local SDK patch removes the earlier649-era Python Mono12 rejection rather than preemptively gate the lane; actual matching private Mono12 SDK/runtime/workload-pack execution remains unproven. Actual MonoAOT/LLVM, WASM, MAUI/device and R2R-interpreter workloads, and full paired/noise validation, remain outstanding. This is not a global SAFE verdict or merge approval. The separate BDN PR does not exist yet, so the published draft retains its explicit temporary overlap and unresolved prerequisite threads. After checking the composition I restored the published source and rebuilt its original net12 configuration successfully; the worktree is clean. The replayable SDK-only patch, exact validation manifest and logs are retained in the owning Copilot session. Root-fixed SDK12 follow-up: Locally recomposed against edf41b94, including its package-root alignment before Arcade imports. The same Python command above now passes 192 tests, including the two new package-root tests. The SDK-only patch is byte-identical across e1/edf and isolated-index replay reproduces the new composed tree An isolated net12 CoreRun publish-path diagnostic driven by the .NET CLI host then completed with exit 0 and 4 actual workloads. Restore used a new private package cache; launch used a private fallback containing only junctions to that cache's non-BDN packages, with 0 BenchmarkDotNet packages. Removing exactly the two owned TFM-less DLLs after the woven host build forced generated recompilation rather than reusing a stale woven binary. Raw PE metadata confirms This closes the local SDK12 custom-root diagnostic gap for the edf composition only. It is not actual Mono execution or a global SAFE verdict. Actual Mono/WASM/device/cohort and paired/noise limitations above remain. Published source/index are restored cleanly; rebuilding the original published net12/BDN649 configuration passed with 0 warnings/errors. No global patch was pushed into this draft, no lanes were removed or measured runtimes substituted, and publication of the SDK-only layer still awaits the separately owned BDN prerequisite. Rebased prerequisite follow-up (October 28): Fetched canonical main The same commands in the table above now pass 206 Python / 102 harness / 13 Reporting / 24 ResultsComparer tests, both net11/net12 builds with 0 warnings/errors, and 1 actual net12 Guid benchmark on BDN These are local SDK integration results, not actual Mono/WASM/device/cohort or paired/noise SAFE evidence. The separately owned campaign remains open. Published source/index are again restored cleanly at Enum compatibility follow-up: Recomposition onto eabc68fa applies the identical SDK-only patch without conflicts and reproduces tree The full net12 harness command above now passes 104 tests. Additional command WASM reference-gather follow-up: Exact 3c025ca8 composes without conflicts using the identical SDK-only patch; replay reproduces tree Published source/index are restored cleanly at |
Merge current dotnet/performance main 166f109 additively. Remove obsolete per-framework BDN595/649 selection and version propagation, retain upstream compatibility unchanged, and preserve framework-specific library dependencies and historical runtime arguments. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
There was a problem hiding this comment.
🟡 Changes recommended
The net11 dependency freeze leaves System.Numerics.Tensors tied to the advancing package version, and the regression test misses this because it checks only intermediate properties rather than the actual PackageReference version.
3 open issues
3 resolved since last review
Review effort: Balanced
Select private runtime and targeting pack versions before SDK framework resolution. Keep manifest-based public selection unchanged and skip static web assets only during CoreCLR reference gathering. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
There was a problem hiding this comment.
🔵 Needs a closer look
The net11 tensor benchmarks still use the main dependency version for System.Numerics.Tensors, allowing future updates to change measurements while the regression test passes without checking the actual package reference.
3 open issues
Review effort: Balanced
Resolve the existing channel policy before runtime payload setup and identity generation. Only explicitly requested frameworks create runtime framework matrices; removing main.mobile_tfm will make mobile jobs inherit main. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Keep every Android/iOS runtime type previously selected by the YAML default on the single mobile override, including microbenchmark callers. Cover early selection, pipeline target fixtures and override-removal inheritance for all five runtime types. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
There was a problem hiding this comment.
🔵 Needs a closer look
The net11 dependency freeze leaves System.Numerics.Tensors tracking main’s version, allowing dependency updates to change net11 measurements while the regression test passes because it checks properties rather than the actual PackageReference version.
3 open issues
Review effort: Balanced
Avoid leaving a hardcoded manual target to update after the optional mobile override is removed. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
There was a problem hiding this comment.
🔵 Needs a closer look
The net11 dependency freeze leaves System.Numerics.Tensors tied to the changing main version, and the regression test misses this because it checks version properties rather than evaluated package references.
3 open issues
Review effort: Balanced
There was a problem hiding this comment.
🔵 Needs a closer look
The net11 dependency freeze leaves System.Numerics.Tensors tied to the shared version property, allowing main-library updates to change net11 measurements without detection by the property-only regression test.
3 open issues
Review effort: Balanced
Use the historical WASM selector and shared flavor normalization for net12. Cover Python forwarding and real BDN parsing for CoreCLR, Mono interpreter and Mono AOT. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
There was a problem hiding this comment.
🔵 Needs a closer look
The net11 dependency freeze leaves System.Numerics.Tensors tracking the main package version, while the regression test checks only alias properties and therefore misses the benchmark dependency drift.
3 open issues
Review effort: Balanced
Pin only net11 System.Numerics.Tensors to 11.0.0 and verify actual evaluated package references for current and future main pins across net8 through net12. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
There was a problem hiding this comment.
🔵 Needs a closer look
The SDK/TFM rollover requires owner review because workload-cohort compatibility, Mono/WASM, mobile/device and R2R-interpreter execution, and Azure pipeline expansion remain unverified.
2 open issues
1 resolved since last review
Review effort: Balanced
Install SDK8 and SDK10 with UseDotNet in the shared tooling root, then install main's daily SDK last. Explain daily acquisition and numeric TFM-major selection, and cover ordering, paths and installer arguments. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
There was a problem hiding this comment.
🔵 Needs a closer look
Parser/property tests and a CoreCLR WASM publish do not establish compatibility across the affected Mono/WASM, mobile, and R2R-interpreter lanes, leaving runtime/device execution and Azure pipeline expansion unverified.
2 open issues
Review effort: Balanced


Summary
Move desktop and WASM main-channel measurements to SDK12 /
net12.0, without implicitly rolling net11 measurements onto runtime12.net12.0/nativeaot12.0.global.net11.json. Older-onlybenchmarks_ci.pyruns temporarily select the newest requested framework's versioned pin and restore the original root file even on failure.--wasmRuntimeFlavor CoreCLR, real Mono/WASM lanes and framework-aware R2R-interpreter selection, including its custom pack/compiler and interpreter settings. Net12 now uses the same legacywasmnet12_0selector for both flavors; the merged BDN compatibility layer selects the actual CoreCLR, Mono interpreter or Mono AOT toolchain. No lanes are disabled or measured modes substituted.Staged policy and one follow-up
The previous rollover was also staged: dotnet/performance#5014 moved the SDK while retaining the previous TFM; dotnet/performance#5064 later switched the TFM. dotnet/performance#5070 updated selectors but still documented missing BDN WASM support. MAUI catch-up in dotnet/performance#5030 also required temporary workload disabling and manual re-enablement tracking. That history was not an automatic, healthy transition for every workload.
This PR instead keeps the temporary decision visible in the existing channel map:
This is the only mobile-version policy. The runtime YAML wrapper forwards only an explicitly requested framework; otherwise a shared early resolver uses existing channel/release-branch rules before framework validation, build-config identity or native Mono payload creation. It covers both mobile scenario families and all five Android/iOS runtime types previously selected by the YAML, including microbenchmark callers. SDK/target metadata remain independent: mobile targets net11 while recording/using SDK12. Versioned channels and explicit framework matrices retain their requested values.
One follow-up: when upstream MAUI/macios net12 branches and workloads support these scenarios, remove
main.mobile_tfm. Mobile jobs then inherit main without another YAML or Python version edit. Tests remove the field and verify inheritance across every mobile scenario family and runtime type. Manual setup documentation also derives the selected TFM from this policy rather than retaining another hardcoded target. There are no new readiness probes, remote fallback mechanisms or guesses that SDK major implies MAUI-supported TFM.Metadata-only pipeline difference: default runtime jobs no longer create a single-entry framework matrix, so Azure job/log artifact names drop that matrix suffix. They still run one job, with the same resolved-TFM benchmark metadata and Helix identities. Explicit framework matrices remain unchanged. Source-checked pipeline fixtures cover the one-job/TFM contract; no Azure pipeline expansion or execution was queued here.
Merged BDN prerequisite and history
dotnet/performance#5348 is merged.
4982f8c80additively integrates upstream main166f1098c52ab216f4ea6167d2e4aec1374a001f;175f7b7b8fixes private-pack coherence/gathering;c2be5a857centralizes and documents the staged policy. Current headdfcda865e0954302af918b29d5d23c36a70d73b7simplifies the net12 WASM selector and adds focused argument/actual-parser regressions. Published history is preserved without rebase, amend or force push.All frameworks use main's shared BDN
0.16.0-nightly.20261029.662. Obsolete per-TFM BDN splits/reference propagation and duplicate compatibility scaffolding are removed. This PR does not change BDN versions/feeds, benchmark libraries, producer artifact contracts or pools. Accepted BDN measurement differences remain the separate update's documented follow-up, not a reopened shipping decision or a SAFE claim.Local validation
Windows x64, private SDK
12.0.100-alpha.1.26527.106;$sdk = (Resolve-Path tools\dotnet\x64).Path, private SDK on PATH and this checkout'sscriptsdirectory on PYTHONPATH. The first two results below are from the current selector-only cleanup. They verify Python argument forwarding and the actual normalized BDN runtime/toolchain types for net12 CoreCLR, Mono interpreter and Mono AOT, not execution of those WASM runtimes.The 298-test and actual desktop execution results were run with the final staged-policy resolver implementation (
4e4313e5d;c2be5a857changed documentation only), not rerun for the selector-only cleanup. Remaining desktop baseline results are explicitly from merged-composition commit4982f8c80, not rerun claims for this head.python -m pytest scripts\tests\test_channel_map.py -k 'wasm_runner_arguments or unknown_wasm_framework' -q --tb=shortdotnet test src\tests\harness\BenchmarkDotNet.Extensions.Tests\BenchmarkDotNet.Extensions.Tests.csproj --configuration Release --framework net12.0 -p:PERFLAB_TARGET_FRAMEWORKS=net12.0 --no-restore --filter 'FullyQualifiedName~Tests.RuntimeArgumentCompatibilityTests' --nologo --verbosity minimalCsProjCoreWasmToolchain,CsProjMonoWasmToolchainandCsProjMonoWasmAotToolchainfor the net12 legacy forms; existing runtime/compatibility cases remain covered. Default-parallel build succeeded.python -m pytest scripts\tests\test_channel_map.py scripts\tests\test_dotnet.py scripts\tests\test_run_performance_job.py scripts\tests\test_blazor_workload.py scripts\tests\test_wasm_coreclr_r2r.py -q --tb=shortpython scripts\benchmarks_ci.py --frameworks net12.0 --dotnet-path $sdk --filter '*Perf_Guid.NewGuid*' --bdn-arguments '--job Dry'12.0.0-alpha.1.26527.106; global time 37.72 s. The repository-configured job ran, not literal Dry.dotnet clean src\tests\harness\BenchmarkDotNet.Extensions.Tests\BenchmarkDotNet.Extensions.Tests.csproj --configuration Release --framework net12.0 -p:PERFLAB_TARGET_FRAMEWORKS=net12.0 --nologo --verbosity quiet4982f8c80, followed by the default-parallel test below.dotnet test src\tests\harness\BenchmarkDotNet.Extensions.Tests\BenchmarkDotNet.Extensions.Tests.csproj --configuration Release --framework net12.0 -p:PERFLAB_TARGET_FRAMEWORKS=net12.0 --nologo --verbosity minimal4982f8c80, 0 failed/skipped. Clean default-parallel build without-m:1or Reporting.dll collision.dotnet test src\tools\Reporting\Reporting.Tests\Reporting.Tests.csproj --configuration Release --framework net12.0 --nologo --verbosity minimal4982f8c80.dotnet test src\tools\ResultsComparer.Tests\ResultsComparer.Tests.csproj --configuration Release --framework net12.0 --nologo --verbosity minimal4982f8c80, including nativeaot12 archives.python scripts\benchmarks_ci.py --frameworks net11.0 net12.0 --dotnet-path $sdk --build-only --filter '*Perf_Guid.NewGuid*'4982f8c80, same shared BDN662. Net11 was not executed.git diff --checkandgit diff --cached --checkEarlier SDK acquisition and isolated package-root results remain historical evidence in the integration notes.
Current-cohort WASM coherence and final publish
An existing Linux x64 CoreCLR WASM Release producer at runtime source
527d68e14a3fe661a496bf2f58ac58e96a90f23asupplied executable SDK12.0.100-alpha.1.26528.120and private12.0.0-ciruntime/ref, WebAssembly, Crossgen2 and ILLink packs. This is the retained November 3 cohort, not the SDK26471 control or a claim about later cohorts. No new producer, CI queue, Helix job or lab execution was started.The original merged composition reproduced NETSDK1112:
net12.0correctly selectedTargetsCurrent=true, but runtime resolution chose manifest version12.0.0-alpha.1.26528.120while the real runtime-pack directory existed only at12.0.0-ci. SDK12/net12 alignment alone did not fix that mismatch.175f7b7b8applies the already explicitPERFLAB_WASM_PACKAGE_VERSIONto the matchingMicrosoft.NETCore.Appframework reference beforeProcessFrameworkReferences, skipping the contradictory late manifest rewrite only for private CoreCLR. Runtime framework, resolved runtime/ref packs, assets and runtimeconfig now agree with the physical pack. Ordinary unset/public and Mono paths retain previous behavior. No directory relabeling, new cohort-version knob, major roll-forward or producer/package change is used.That commit also disables static web assets only for CoreCLR
BenchmarkDotNetGatherReferences=true, because BDN skips entry-DLL compilation in that pass. Final publishing and all output/routing guards remain enabled. The current policy and selector follow-ups leave these MSBuild/WASM target files unchanged.Local Ubuntu 24.04 WSL, isolated SDK/cache. Original executable modes stripped by payload preparation were restored from the producer archive; binaries and cohort identities were not changed. The host command
python3 scripts/benchmarks_ci.py --frameworks net12.0 --dotnet-path "$DOTNET_ROOT" --build-only --wasm --wasm-runtime-flavor CoreCLR --wasm-ready-to-run-composite --filter '*Perf_Guid.NewGuid*'restored/built with 0 warnings/errors before the pack fix.A temporary diagnostic then used BDN662's genuine
CsProjCoreWasmToolchain.Builder.BuildAsyncforPerf_Guid.NewGuidin a fresh generated directory, without any executor/JavaScript engine. The fresh restore/gather/full-publish results below were obtained with175f7b7b8; after the final resolver implementation, the final--no-restorecommand was rerun incrementally against the same cohort and output. It is not a second fresh compilation or V8 execution. These commands were not rerun for the subsequent selector-only cleanup.For these effective commands, the working directory is the generated project directory,
DOTNET_ROOTis the producer SDK andNUGET_PACKAGESthe isolated cache.PERFLAB_WASM_PACKAGE_VERSION=12.0.0-ci, matching producer Crossgen2 task overrides and both requested R2R/composite flags remain enabled.dotnet restore gen.csproj /p:ArtifactsPath="$PWD/a" /p:RestorePackagesPath="$NUGET_PACKAGES" /p:BenchmarkDotNetGatherReferences=true --nodeReuse:false /p:UseSharedCompilation=false /p:Deterministic=true /p:Optimize=true -bl:gen-restore.binlog175f7b7b8.dotnet build gen.csproj -f net12.0 -c Release /p:ArtifactsPath="$PWD/a" /p:BenchmarkDotNetGatherReferences=true --no-restore --nodeReuse:false /p:UseSharedCompilation=false /p:Deterministic=true /p:Optimize=true /p:RestorePackagesPath="$NUGET_PACKAGES" -bl:gen-build-no-restore.binlogdotnet publish gen.csproj -f net12.0 -c Release /p:ArtifactsPath="$PWD/a" --nodeReuse:false /p:UseSharedCompilation=false /p:Deterministic=true /p:Optimize=true /p:RestorePackagesPath="$NUGET_PACKAGES" -bl:gen-publish.binlog175f7b7b8.dotnet publish gen.csproj -f net12.0 -c Release --no-restore /p:ArtifactsPath="$PWD/a" --nodeReuse:false /p:UseSharedCompilation=false /p:Deterministic=true /p:Optimize=true /p:RestorePackagesPath="$NUGET_PACKAGES" -bl:gen-publish-staged-policy.binlogGenerated-project binlogs verify SDK26528.120, net12/current, CoreCLR/browser-wasm/self-contained, initial runtime framework and resolved runtime/ref packs
12.0.0-ci, with the real pack directory anddata/RuntimeList.xml. The alpha-version runtime-pack directory is still absent. Final R2R/composite/trimming/WebCIL/static-assets flags are alltrue; gather-only static assets/R2R/WebCIL are off.The actual 175,463,021-byte composite WASM owner remains
MicroBenchmarks-gen.r2r.60c6e8u671.wasm, SHA256ba2f9bf1a1e5d0d18c07ae8cc229bac129b87207721401f68a516a1bba2a5b21. Verified WASM magic, compiler-output/published-asset/boot integrity equality and embedded loader routing withisCompositeImage=true. Runtimeconfig records net12 / Core12ci. All three final configuration/output/composite-routing guards succeeded, including the latest no-restore regression.Remaining limits
Keep this PR draft. The exact retained SDK26528.120 final-publish gate passes for the versions noted above; actual V8/Mono/device or R2R-interpreter execution, later-cohort coverage, MAUI acquisition/device tests, the full Helix matrix, CertHelper and Startup tests are not established here. No performance-safety/SAFE or ready/merge claim. Actual Mono/WASM execution review threads remain open.
The one planned mobile catch-up is removal of
main.mobile_tfmonce upstream net12 support is available and verified—not another round of scattered framework selectors.