Migrate Windows arm64 release build to native windows-11-arm runner - #15437
Draft
warp-agent-staging[bot] wants to merge 3 commits into
Draft
Migrate Windows arm64 release build to native windows-11-arm runner#15437warp-agent-staging[bot] wants to merge 3 commits into
warp-agent-staging[bot] wants to merge 3 commits into
Conversation
Contributor
Author
|
This PR was generated with Warp. Comment |
warp-agent-staging
Bot
force-pushed
the
factory/win-arm64-native-build
branch
from
August 22, 2026 01:46
b110f7e to
5bc22f8
Compare
warp-agent-staging
Bot
force-pushed
the
factory/win-arm64-native-build
branch
from
August 23, 2026 00:49
5bc22f8 to
8a9c508
Compare
Base automatically changed from
david/optimize-settings-schema-generation-during-release
to
master
August 23, 2026 01:21
Both windows-11-arm and windows-2025 GitHub-hosted runner images now ship the same VC++/Windows SDK/LLVM toolchain, so the arm64 leg of the Windows release build no longer needs to cross-compile from an x86_64 host. - .github/workflows/create_release.yml: point the arm64 leg of build_windows_binaries and release_windows (already keyed by a per-arch matrix.runner) at windows-11-arm instead of windows-latest-large. Give build_windows_tui_binaries and release_windows_tui the same per-arch matrix.runner treatment (they previously had a flat runs-on: windows-latest-large). Drop the 'Add arm64 target' rustup steps, since the arm64 leg's host target is now aarch64-pc-windows-msvc rather than a cross-compiled add-on. Disable azure/artifact-signing-action's dependency cache (cache-dependencies: false) in both signing steps, since it is not keyed by runner architecture and can otherwise be corrupted when the x64 and arm64 legs of the matrix sign concurrently (Azure/artifact-signing-action#146). - script/install_cargo_binstall: pin the aarch64-pc-windows-msvc cargo-binstall archive and its verified SHA-256 alongside the existing x86_64 entry, so the installer can resolve a native arm64 archive if it is ever selected.
archive_for_platform derived the Windows archive name from `uname -m`, but Git for Windows' MSYS runtime does not report the host's real architecture there: it reports the emulated x86_64 process architecture under WOW64, or "unknown" for a native arm64 host with no case in its uname implementation. On windows-11-arm this asked for cargo-binstall-unknown-pc-windows-msvc.zip, which has no pinned digest, and the script exited before installing anything. Derive the Windows architecture from PROCESSOR_ARCHITEW6432 (set only under WOW64/x64 emulation, to the true native architecture) falling back to PROCESSOR_ARCHITECTURE instead, so both a native arm64 host and an x64-emulated bash on an arm64 host resolve to the aarch64 archive. The x64 leg still resolves to the same x86_64 archive as before.
DO NOT MERGE THIS COMMIT. It exists only so this migration's Windows arm64 path can be exercised on its own, without paying for the full release matrix. Revert it (a single, self-contained commit) before this PR merges. Re-derived against the workflow as restructured by the commits this branch is now rebased onto (release_macos_cli and release_linux_cli_x86 split into build-only + packaging-only jobs, gate_tui_release_artifacts replaced by collect_results). The previous version of this commit hardcoded if: false on every non-Windows job by name; that approach no longer matches the current job list and, more importantly, collect_results derives which platforms are "disabled" from the build_macos/build_linux/build_windows/ build_web workflow inputs, not from each job's own if:, so hardcoding if: false directly on jobs would have made collect_results treat every one of them as a genuine, non-excluded failure and fail the whole run. Instead, this flips the *default* of the build_linux, build_macos, and build_web workflow_dispatch inputs to false (the workflow_call inputs used by real automated releases are untouched). A manual test run started with no input overrides now disables those three platforms through the exact same mechanism a user could already invoke by hand, so collect_results correctly excludes them instead of reporting spurious failures. Within Windows, isolates the arm64 leg of build_windows_tui_binaries, release_windows_tui, and release_windows by commenting out the x64 entry in each job's matrix.include, rather than by adding a matrix condition to the job's if:. jobs.<job_id>.if only has access to the github, needs, vars, and inputs contexts (see the context availability table in GitHub's docs); matrix is not among them, so a job-level if: referencing matrix.arch silently evaluates to an empty-string comparison and is always false. This was the flaw in the very first attempt at this scaffolding. build_windows_binaries is deliberately left running both legs: its x64 leg alone produces the canonical Windows settings schema artifact that the arm64 legs of release_windows and release_windows_tui download.
vorporeal
force-pushed
the
factory/win-arm64-native-build
branch
from
August 23, 2026 01:21
8a9c508 to
4da56ca
Compare
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 join this conversation on GitHub.
Already have an account?
Sign in to comment
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.



Warning
This PR currently carries a temporary test-only commit that must be removed before merge:
TEMPORARY TEST SCAFFOLDING: isolate Windows arm64 in create_release.yml(commit8a9c508). It restricts a manualworkflow_dispatchrun to the Windows arm64 path only, so the migration can be tested without running the full release matrix. Drop that one commit (a single, self-contained revert/rebase) before merging. See "Temporary test-only commit" below for exactly what it does.Summary
Migrates the Windows arm64 release build (both the main app and the TUI) from x86_64 cross-compilation to native compilation on the
windows-11-armGitHub-hosted runner. The Windows 11 Arm64 GA runner image now ships the same VC++/Windows SDK/LLVM toolchain as the x64 image, so cross-compilation is no longer necessary. Stacked on #13240.Changes
build_windows_binaries/release_windows: changed the arm64 leg'smatrix.runnerfromwindows-latest-largetowindows-11-arm(the x64 leg is untouched).build_windows_tui_binaries/release_windows_tui: gave these jobs the same per-archmatrix.runnertreatment (they previously had a flatruns-on: windows-latest-large), pointing the arm64 leg atwindows-11-arm.Add arm64 target(rustup target add aarch64-pc-windows-msvc) steps in the two build jobs, since the arm64 leg's host target is nowaarch64-pc-windows-msvcrather than a cross-compiled add-on.azure/artifact-signing-action's dependency cache (cache-dependencies: false) in both signing steps. That cache is not keyed by runner architecture, so the x64 and arm64 legs of the matrix can corrupt each other's cached tools when they sign concurrently (Azure/artifact-signing-action#146).script/install_cargo_binstall: pinned theaarch64-pc-windows-msvccargo-binstall archive and its verified SHA-256 alongside the existing x86_64 entry, and fixedarchive_for_platform's Windows arch detection to readPROCESSOR_ARCHITEW6432/PROCESSOR_ARCHITECTUREinstead ofuname -m(Git for Windows' MSYS runtime doesn't report the true host architecture there, so the aarch64 entry was otherwise unreachable).Temporary test-only commit
The final commit on this branch,
TEMPORARY TEST SCAFFOLDING: isolate Windows arm64 in create_release.yml, is scaffolding for manually testing this migration, requested for after code review passes. It is not part of the migration itself and must be dropped before merge. It:build_linux,build_macos, andbuild_webworkflow_dispatch inputs tofalse(theworkflow_callinputs used by real automated releases are untouched).collect_resultsderives which platforms are "disabled" from these same inputs, so a default manual test run correctly excludes those platforms from its pass/fail rollup instead of reporting a spurious failure.build_windows_tui_binaries,release_windows_tui, andrelease_windowsby commenting out the x64 entry in each job'smatrix.include(not via a job-levelif:, sincejobs.<job_id>.ifcannot see thematrixcontext).build_windows_binariesrunning both legs unchanged, since its x64 leg alone produces the canonical Windows settings schema artifact the arm64 release jobs depend on.A manual
workflow_dispatchrun ofcreate_release.yml(withchannelandbuild_windows: true, leavingbuild_linux/build_macos/build_webat their default) will therefore exercise only:prepare_release→build_windows_binaries(both legs) →build_windows_tui_binaries(arm64 only) →release_windows(arm64 only) andrelease_windows_tui(arm64 only) →collect_results. Every other release job is skipped and correctly excluded fromcollect_results' pass/fail rollup.Verification
This can only be fully verified by actually running the workflow on
windows-11-arm, which I can't do from here. What I checked instead:if:,matrix.include, and theworkflow_dispatch/workflow_callinput defaults resolve as expected (verified withjs-yaml), including confirming no job-levelif:references thematrixcontext (cross-checked against GitHub's documented context availability table, which lists onlygithub, needs, vars, inputsforjobs.<job_id>.if) and that theworkflow_callinput defaults are untouched.script/install_cargo_binstall's new SHA-256 forcargo-binstall-aarch64-pc-windows-msvc.zipwas independently verified by downloading the v1.18.1 asset and computing its digest locally.PROCESSOR_ARCHITEW6432/PROCESSOR_ARCHITECTUREdispatch logic was sanity-checked in isolation underbash -ufor all three relevant cases: an unemulated x64 host (unchanged from before), an arm64 host running x64-emulated Git Bash, and an arm64 host running native arm64 Git Bash.script/windows/build_inno_sign_tool_command.ps1needs no change: the Windows SDK installsx86,x64,arm, andarm64signtool.exesubfolders side-by-side on every host regardless of its own architecture, and Azure's Trusted Signing dlib has no arm64 build at all, so the script's existingx64filters remain correct — an arm64signtool.execan't load the x64-only dlib anyway.protocinstall (choco + winget fallback inprepare_environment) needs no change either: neither package publishes an arm64 Windows archive, but the x64 archive runs fine under Windows 11 arm64's built-in x64 emulation, which only affects toolchain install speed, not the codegen it produces.azure/artifact-signing-actionofficially does not support Windows arm64 runners, but multiple public reports confirm it works via x64 emulation as long as its dependency cache is disabled when x64 and arm64 legs of a matrix run concurrently — hence thecache-dependencies: falseaddition above. This, and whether the arm64 build genuinely succeeds end-to-end, remain the parts of this change that only an actual run onwindows-11-armcan confirm.