GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Prebuilt: native Windows arm64 CPU bundle (5-6x faster than the x64 bundle under emulation) by danielhanchen · Pull Request #55 · unslothai/stable-diffusion.cpp

Conversation

@danielhanchen

@danielhanchen danielhanchen commented Nov 8, 2026 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Member

Windows on ARM hosts have no bundle of their own today: they download win-cpu-x64 and run it under x64 emulation. On a GitHub windows-11-arm runner (Azure Cobalt 100, 4 cores) that is 5-6x slower than a native build of the same commit.

What this adds

A win-cpu-arm64 entry in the build-windows matrix of unsloth-sd-prebuilt.yml:

leg runner asset
win-cpu-arm64 windows-11-arm sd-<tag>-bin-win-cpu-arm64.zip
  • Built with the clang that ships on the runner image, targeting the MSVC ABI (MSVC environment from ilammy/msvc-dev-cmd with arch: arm64). MSVC proper has no -march for ARM, and ggml then insists on GGML_NATIVE, which would bake in the build host's CPU.
  • ggml has no CPU variant set for Windows on ARM (GGML_CPU_ALL_VARIANTS covers Linux, Android and macOS only), so this is one build for armv8.2-a+dotprod+fp16, which every Windows 11 ARM64 CPU has (Snapdragon 850 / 7c / 8c / 8cx / X, Microsoft SQ, Ampere Altra, Cobalt 100). OpenMP is off (no OpenMP runtime for clang on the image); ggml's own threadpool takes over.
  • Best effort, like the CUDA legs: continue-on-error and not in the coverage gate, so it can never hold back the seven required CPU / Apple / Vulkan assets. The release notes mention it next to CUDA.
  • A new Native arm64 gate step: every PE in the finished zip must be machine 0xAA64, and sd-cli --help must start and exit 0 on the runner. Without it an x64 bundle would pass every other gate, because the arm64 runner emulates x64 too.
  • The x64 entries are unchanged apart from naming their runner in the matrix; Ninja for the arm64 entry comes from pip.

Studio picks this asset up with no Studio change: resolve_release_asset in studio/install_sd_cpp_prebuilt.py filters Windows assets by the host arch (arm64 / aarch64). Run against a release asset list with and without win-cpu-arm64 over 225 cells (Windows / Linux / macOS x AMD64 / x86_64 / ARM64 / aarch64 / arm64 x auto / cpu / cuda / vulkan / rocm x CUDA major), 18 cells move and all 18 are Windows arm64 with auto / cpu: today they get no mirror asset (and upstream has no Windows arm64 asset either, so Studio builds from source), with this leg they get win-cpu-arm64. Every x64, Linux and macOS cell picks the same asset as before. A release where this best-effort leg failed is the same as today for those hosts.

Validation

what result
this workflow on staging (resolve + this leg, signing gate dropped since staging has no signing secrets) builds, packages sd-...-bin-win-cpu-arm64.zip (31.2 MiB, sd-cli.exe + sd-server.exe), native arm64 gate passes: both PEs 0xAA64, sd-cli --help exits 0 on Cobalt 100
same, merged with #48 (ARM K-quant / I-quant GEMMs) builds and passes the gate (31.6 MiB)
the gate's PE check on the current win-cpu-x64 release zip every PE is 0x8664, so the gate would reject it

SD1.5, 256x256, 4 steps euler, seed 42, -t 4, windows-11-arm runner (Cobalt 100), 3 interleaved repeats per arm, sampling time median [repeats]:

arm F16 sampling (s) Q8_0 sampling (s) VAE (s)
shipping win-cpu-x64 release (aba3a1c) under emulation, haswell variant 64.08 [64.50, 64.08, 63.41] 63.53 [63.83, 63.47, 63.53] 27.43
same commit aba3a1c, native arm64 build with this leg's flags 12.80 [13.02, 12.80, 12.64] 10.61 [10.80, 10.61, 10.59] 6.56
master ba6ac30, native arm64 12.74 [13.24, 12.74, 12.65] 10.95 [10.95, 11.30, 10.56] 6.61

Native is 5.0x (F16) and 6.0x (Q8_0) faster in sampling and 4.2x in VAE decode than the x64 bundle Windows on ARM users run today. Each arm gave the same pixels on every repeat.

Signing on the arm64 runner, partly checked: on a windows-11-arm runner the pinned trusted-signing-cli 0.10.0 (x64) downloads with the expected sha256, starts under emulation (--version exits 0), and its default signtool path (Windows Kits\10\bin\10.0.26100.0\x64\signtool.exe) exists on the image. An actual signature needs the release secrets, which staging does not have.

Not proven: a real signature on the arm64 runner; Windows on ARM hardware other than Cobalt 100 (no Snapdragon runner is available); a clean Windows on ARM machine without the arm64 Visual C++ runtime (the bundle links the MSVC runtime dynamically, the same as win-cpu-x64 does today).

Related: the Windows arm64 clang defines __ARM_NEON but not __ARM_NEON__ (checked on the runner), so this bundle's flash attention GEMM uses the 2 x 2 tile until #67 lands; with #67 it renders identical pixels (FLUX.2 klein 512 px on Cobalt 100).

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

chatgpt-codex-connector[bot] reacted with thumbs up emoji
All reactions
  • 👍 1 reaction
@danielhanchen
Prebuilt: native Windows arm64 CPU bundle (clang, armv8.2-a + dotprod…
c0f2123
… + fp16)

Windows on ARM hosts run win-cpu-x64 under x64 emulation today. Add a
win-cpu-arm64 leg on windows-11-arm, built with the runner's clang for the
MSVC ABI (MSVC has no -march for ARM and ggml has no Windows ARM CPU
variants), OpenMP off. Best effort like the CUDA legs, so it cannot hold
back the seven required assets. A new gate checks every PE in the zip is
ARM64 and that sd-cli starts natively.
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 8, 2026 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-09T19:05:06.360259Z a46bda5 Manual request
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@danielhanchen danielhanchen mentioned this pull request Nov 8, 2026
CPU: tinyBLAS GEMM for Q4_1 / Q5_0 / Q5_1 weights (x86 bit-identical, 1.5-2.2x) and BF16 on ARM (19x) #56
Merged
@danielhanchen danielhanchen self-assigned this Nov 9, 2026
@danielhanchen danielhanchen mentioned this pull request Nov 9, 2026
Resync with upstream master-1056 (packed INT4 convrot, MiniMax-H3 QKV chunking, RelayVSR, SDXL ControlNet Union) #54
Merged
@danielhanchen
Shorten the Windows arm64 workflow comments
a46bda5
@danielhanchen

danielhanchen commented Nov 9, 2026

Copy link
Copy Markdown
Member Author

@codex review

chatgpt-codex-connector[bot] reacted with eyes emoji
All reactions
  • 👀 1 reaction

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

1 similar comment
@danielhanchen

danielhanchen commented Nov 9, 2026

Copy link
Copy Markdown
Member Author

@codex review

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 9, 2026

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. Keep it up!

Reviewed commit: a46bda5deb

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@danielhanchen
danielhanchen merged commit 4d6820b into master Nov 9, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

No reviews

Uh oh!

There was an error while loading. Please reload this page.

Assignees

@danielhanchen danielhanchen

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

Uh oh!

There was an error while loading. Please reload this page.

1 participant

@danielhanchen
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.
You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.