ggml's CMake defaults GGML_NATIVE=ON, which adds -march=native and silently
enables every extension the build runner's CPU advertises. Recent Azure
ubuntu-latest hosts are Xeon Platinum 8370C (AVX-512 capable), so the
master-593 release of libstable-diffusion.so was built with 5,396 zmm /
1,582 k-mask AVX-512 instructions and SIGILLs immediately on any consumer
or CI host without AVX-512.
Pin the Linux x86_64 cpu and ROCm builds to GGML_NATIVE=OFF +
GGML_AVX2=ON + GGML_FMA=ON + GGML_F16C=ON — a portable Haswell-era
baseline that downstream consumers (Lemonade, end users) can rely on.
The Windows AVX2 cpu build and Windows ROCm builds already use
GGML_NATIVE=OFF; this brings Linux into line.
Verified by inspecting libstable-diffusion.so:
master-569 (no AVX-512): 0 zmm refs, 0 k-mask refs
master-593 (AVX-512): 5,396 zmm refs, 1,582 k-mask refs
The crash this fixes manifests in lemonade-sdk/lemonade CI as
sd-server "exit code: -1" within 200ms on the GitHub-hosted ollama
test job, while the self-hosted ROCm runner (full AVX-512) succeeds.
* ci: add macOS arm64 (Metal) build for stable-diffusion.cpp
Adds a macos-arm64-cmake job covering [macos-14, macos-latest] that builds
leejet/stable-diffusion.cpp with Metal enabled and produces a release-ready
sd-*-bin-Darwin-macOS-<ver>-arm64.zip artifact, mirroring the existing Linux
job's naming convention. Wired into the release job so macOS arm64 binaries
are attached alongside Linux/Windows on scheduled and manual releases.
* ci(macos): bake @loader_path rpath so dylib loads next to binary
Without this, sd-cli ships with the GitHub runner's absolute build path
hardcoded in its rpath and fails at runtime with 'Library not loaded:
@rpath/libstable-diffusion.dylib'. Mirrors llama.cpp's release.yml flags.
* ci(macos): use stable artifact filename without OS version
Drop the dynamic Darwin-macOS-{sw_vers}-arm64 suffix in favor of a stable
sd-{branch}-{hash}-bin-Darwin-arm64.zip name (with -latest variant for
macos-latest). The previous naming embedded the runner image's macOS
point release (e.g. 14.8.5, 15.7.4), which churns silently as GitHub
patches the image and would break downstream consumers (Lemonade C++)
that download by exact filename. Matches the fixed-name pattern already
used by the Windows builds.
* ci: grant contents:write so the release job can publish artifacts
Without this, the workflow's GITHUB_TOKEN defaults to read-only on forks
and the 'Create release' / 'Upload release' steps fail with HTTP 403
'Resource not accessible by integration'. Same fix the Linux/Windows
release flow needs to function on Geramy's fork; safe on upstream where
the org-default token already has write access (this just makes it
explicit and forks-portable).
* ci(macos): name artifact …Darwin-arm64-metal.zip to align with backend ID
Lemonade's recipe matrix is adopting a 'metal' backend identifier for
macOS arm64 (mirroring the existing llamacpp/metal pattern). Renaming
the artifact's suffix to match keeps Lemonade C++'s download URL
construction trivial (filename = sd-{ver}-bin-Darwin-arm64-metal.zip)
and signals to consumers that this build has Metal acceleration enabled
(GGML_METAL=ON GGML_METAL_USE_BF16=ON GGML_METAL_EMBED_LIBRARY=ON).
AMD is in the process of moving over to a brand new build system (TheRock).
They have a preview release stream for it, and it includes some significant
performance uplifts.
To let people experiment with both stacks generate artifacts both for the
stable (7.2.1) and preview (7.12) stacks.
In both cases - ROCm must be installed first to use this artifact.
It's intentionally not bundled because so many ISAs are included and the
size of the artifact balloons to an untenable size.
This builds from ROCm release tarballs. In order to use it you
must have ROCm installed in the operating system first.
- Update GPU_TARGETS to match Linux job (7.11.0 targets)
- Cache DLL's from extracted tarball directory instead of installer directory
- Align Windows and Linux ROCm build configurations
Also; rename the legacy ROCm task to clarify which artifacts come
from which release.
* feat: add support for the eta parameter to ancestral samplers
* feat: Euler Ancestral sampler implementation for flow models
* refine flow ancestral sampling and normalize eta defaults
---------
Co-authored-by: leejet <[email protected]>