Where runtime Helix minutes go, and why WebAssembly is a large share
Maintainer antworten meist innerhalb von 1 Tag
Dieses Issue hat noch niemand übernommen.
Bewertung
- Schwierigkeit
- 5/5
- Geschätzter Aufwand
- Über eine Woche
- Anfängerfreundlichkeit
- 20/100
- Issue-Typ
- Dokumentation
- Klarheit
- Muss geklärt werden
- Aktivitätsstatus
- Aktiv
- Tech-Stack
- csharp, github-actions, wasm
- Bereich
- ci-cd, performance
Rechercherichtung
This issue is an informational analysis and does not propose a specific change. It references eng/pipelines/runtime.yml and evaluate-default-paths.yml, plus the Chrome and Wasmtime library-test templates; read those alongside the trigger observations in section B3. The issue offers several options for discussion, but does not identify an agreed action or a completion criterion.
Vom Indexierungsmodell aus dem Issue-Text verfasst.
Beschreibung
This issue summarizes where dotnet/runtime Helix time went over the last seven days. It explains why WebAssembly accounts for a large share and lists some options that may be worth a closer look. It is informational only and does not propose a specific change.
/cc @lewing @steveisok
Data and method
- Window: Nov 20, 21:47 UTC – Nov 27, 21:47 UTC (7 days).
- Source: Helix
WorkItemsjoined toJobsin theengsrvprod/engineeringdataKusto database. - Scope: Jobs whose source is
dotnet/runtime. This includes PRs, rolling CI, and other builds on every branch. - Measure: Total time that completed work items spent running, from start to finish. It does not measure VM uptime, CPU time, billing, queue wait, or Azure Pipelines build-agent time.
- Counting: Each attempt is counted once. Work that began before the window is counted only from the start of the window.
- WebAssembly: Any Helix job that ran in a
*-helix-webassembly*container, on either Linux or Windows hosts.
A. How dotnet/runtime Helix minutes are spent
| Category | Work items | Minutes | Share | PR minutes | CI minutes |
|---|---|---|---|---|---|
| Windows (not WebAssembly) | 1,332,965 | 2,111,664 | 36.8% | 1,163,795 | 738,527 |
| WebAssembly (browser + WASI) | 313,021 | 1,480,909 | 25.8% | 1,082,460 | 397,028 |
| Linux x64 and other | 852,801 | 758,870 | 13.2% | 351,863 | 219,980 |
| Linux arm64 | 712,804 | 685,811 | 11.9% | 328,158 | 211,027 |
| macOS | 536,577 | 563,575 | 9.8% | 229,210 | 333,189 |
| Android | 61,429 | 139,687 | 2.4% | 70,146 | 69,486 |
| Total | 5,740,516 | 3,225,632 |
WebAssembly is about a quarter of all runtime Helix minutes and about a third (33.6%) of PR minutes. Of the 388 runtime PRs that sent any work to Helix in this window, 358 (92%) ran WebAssembly jobs. Those PRs averaged about 22 WebAssembly Helix jobs each.
B. Why WebAssembly minutes are high
B1. Where the WebAssembly minutes go
| Workload | Minutes | Share of WebAssembly | PRs that ran it | PR minutes per PR | Average minutes per item |
|---|---|---|---|---|---|
| Wasm.Build.Tests (SDK app-build tests) | 602,823 | 40.7% | 93 | ~4,850 | 20.1 |
| Library tests in Chrome | 465,685 | 31.4% | 360 | ~760 | 5.9 |
| Library tests in Wasmtime (WASI) | 182,802 | 12.3% | 330 | ~530 | 1.8 |
CoreCLR runtime tests (src/tests) |
176,833 | 11.9% | 367 | ~370 | 2.3 |
| Library tests in Firefox, V8, and others | 52,766 | 3.6% | 359 | ~130 | — |
By host OS, minutes are split about evenly: ~755k on Windows-hosted containers and ~726k on Linux-hosted containers.
- Windows-hosted Wasm.Build.Tests account for about 488k minutes, the largest single bucket. They average about 30 minutes per work item, compared with about 8.4 minutes per item on Linux.
- Windows-hosted Chrome library tests account for about 205k minutes. They come from
release/10.0andrelease/11.0builds and from PRs. These are mostly Mono jobs (WasmTestOnChrome-ST-*andWasmTestOnChrome-MONO-ST-*).mainno longer has Windows Chrome library-test jobs.
B2. Tests take longer per run under WebAssembly
Median runtime in minutes for passing runs of the same test assembly. The native baseline combines several runtime configurations, so treat these ratios as rough.
| Test assembly | Native Linux x64 | Chrome | Firefox | V8 | Wasmtime |
|---|---|---|---|---|---|
| System.Text.Encodings.Web.Tests | 0.35 | 1.63 | 1.78 | 1.53 | 15.77 |
| System.Collections.Immutable.Tests | 1.05 | 3.54 | 3.75 | 2.15 | 13.75 |
| System.Globalization.Tests | 0.88 | 1.68 | 1.58 | 0.98 | 10.23 |
| System.Linq.Expressions.Tests | 0.48 | 1.67 | 1.57 | 1.90 | 8.36 |
| System.Runtime.Tests | 1.93 | 3.27 | 19.04 | 13.87 | 18.38 |
In browsers, the same tests usually take about 1.5–4× as long as native runs. In Wasmtime they often take 10–45× as long. These durations include host and browser startup and test setup, not just WebAssembly execution.
B3. Pipeline triggers
The following refers to eng/pipelines/runtime.yml and its templates at main commit 5b65c8d4.
-
The
librariespath filter matches almost any change. Inevaluate-default-paths.yml, thelibrariessubset has only an exclude list. It therefore matches most changes outsidesrc/coreclr,src/mono,src/tests, and the other excluded paths. This filter is one of the triggers for both of these jobs:- The CoreCLR Chrome library-test job (
wasm-coreclr-library-tests.yml,scenarios: WasmTestOnChrome). - The CoreCLR Wasmtime library-test job (
wasi-wasm-coreclr-library-tests.yml).
Both templates have a
shouldRunSmokeOnly: onLibrariesAndIllinkChangesmode. In that mode, a change that touches libraries or ILLink but nothing WebAssembly-specific runs only the smoke tests.runtime.ymldoes not use that mode for the main Chrome or Wasmtime jobs, so they run the full suites. Only the_SmokeFirefoxV8,_Smoke_R2R, and WASI_R2Rjobs are smoke-only. - The CoreCLR Chrome library-test job (
-
The
wasm_coreclr_runtimetestsfilter includes all ofsrc/coreclr/*andsrc/tests/*. Any CoreCLR or test change therefore triggers:- The browser and WASI CoreCLR builds.
- The WASI CoreCLR runtime tests, both interpreter and ReadyToRun.
- The browser CoreCLR runtime tests. These also run on any change that matches the
coreclrfilter.
-
Wasm.Build.Tests are triggered rarely but cost a lot per run. The
wasmbuildtestsfilter is narrow, along with the ILLink and dependency-flow triggers. Even so, each run sends about 10 Helix jobs that total about 2,300 minutes, mainly on Windows. Active WebAssembly PRs push many times. For example, #138027 used about 28k Wasm.Build.Tests minutes in this window.- Of the 93 PRs,
dotnet-maestrodependency and code-flow PRs accounted for about 66k of the 451k PR minutes. - A few PRs whose titles don't suggest WebAssembly changes also triggered Wasm.Build.Tests, such as #137944 (PAL cleanup) and #137670 (EventPipe file permissions). It may be worth checking which filter they matched.
- Of the 93 PRs,
-
Rolling builds run every WebAssembly job (
alwaysRun: isRollingBuild). They are already batched and scheduled twice a day. Rolling CI used about 397k WebAssembly minutes in this window.
C. Options that may be worth a closer look
These are listed only for discussion. Each one trades some coverage for fewer minutes, and the WebAssembly owners are best placed to judge whether that trade is acceptable.
- Use smoke-only mode for library-only changes. Pass
shouldRunSmokeOnly: onLibrariesAndIllinkChangesto the main CoreCLR Chrome and Wasmtime library-test jobs. Full runs would still happen on rolling builds, outer loop, and changes that match a WebAssembly-specific filter. On Linux, these two jobs used about 360k PR minutes in this window. - Narrow
wasm_coreclr_runtimetests. Instead of all ofsrc/coreclr/*andsrc/tests/*, it could cover only the WebAssembly-relevant areas, such assrc/coreclr/vm/wasm, the interpreter, the JIT, crossgen2/ReadyToRun, and WebAssembly test infrastructure. This would reduce how often the browser and WASI builds and runtime tests run. - Look at the Windows-hosted Wasm.Build.Tests jobs. Each work item takes about 3.5× as long as on Linux, and these jobs account for about a third of all WebAssembly minutes. Options include running a subset on PRs and the full matrix on rolling builds. Another is reducing the per-run fan-out (the Workloads, Webcil, Fingerprinting, and Bundler combinations).
- Review the slowest Wasmtime suites. Some assemblies run 10–45× slower than native. Splitting, trimming, or moving the heaviest ones to outer loop could help without removing WASI coverage.
- Check why some PRs triggered Wasm.Build.Tests. Some PRs that seem unrelated to WebAssembly did, as noted in B3.3.
- Review release-branch Windows Chrome (Mono) jobs. They used about 205k minutes this week in
release/10.0andrelease/11.0, through rolling builds and PRs.
Queries are available on request.
- Vorherrschende Sprache
- C#
- Sterne
- 18.5k
- Forks
- 5.8k
- Ø Merge
- 2 T. 8 Std.
- Gemergte PRs (30 T.)
- 597
Entwicklungsumgebung
Startet den Dev-Container des Projekts im Browser, mit Ihrem eigenen GitHub-Konto.
- Kein Dockerfile und keine Docker-Compose-Datei
- Hat eine Pull-Request-Vorlage
- Beitragsleitfaden lesen
Erste Schritte
- Lesen Sie das ganze Issue und danach den Beitragsleitfaden des Projekts.
- Schreiben Sie ins Issue, dass Sie es übernehmen — das erspart doppelte Arbeit.
- Forken Sie das Repository und arbeiten Sie in einem Branch.
- Öffnen Sie einen Pull Request, der die Issue-Nummer nennt.
Mehr aus dotnet/runtime
-
area-VM-meta-mono untriaged
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 75/100
Maintainer antworten meist innerhalb von 1 Tag
-
area-Debugger-mono untriaged
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 75/100
dotnet/runtime#138494 · 1 Kommentar ·
Maintainer antworten meist innerhalb von 1 Tag
-
area-AssemblyLoader-mono untriaged
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 78/100
dotnet/runtime#138493 · 1 Kommentar ·
Maintainer antworten meist innerhalb von 1 Tag
-
JsonConsoleFormatter throws on NaN and infinite double and float values, failing the log callEvtl. vergeben @Mohamedadel-prog hat das vor 2 Tagen übernommen. Offenarea-Extensions-Logging untriaged
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 82/100
dotnet/runtime#138418 · 2 Kommentare ·
Maintainer antworten meist innerhalb von 1 Tag
-
area-System.IO untriaged
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 78/100
dotnet/runtime#138417 · 1 Kommentar ·
Maintainer antworten meist innerhalb von 1 Tag
Ähnliche Issues
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 76/100
Maintainer antworten meist innerhalb von 1 Tag
-
bug
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 76/100
juandresrodca/AdminForge#69 ·
Maintainer antworten meist innerhalb von 1 Tag
-
Keep PublicAPI.Unshipped.txt sorted, with a guard, so concurrent API PRs stop conflicting on itOffenchore small tooling
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 72/100
Maintainer antworten meist innerhalb von 1 Tag
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 79/100
BattletechModders/ModTek#256 · 1 Kommentar ·
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 65/100
Facepunch/sbox-public#12484 ·
Maintainer antworten meist innerhalb von 2 Tagen