Skip to content

sdk.lock pins the LLVM SDK (#1826) - #1913

Merged
ehartford merged 1 commit into
mainfrom
sdk-pin
Sep 30, 2026
Merged

ehartford merged 1 commit into
mainfrom
sdk-pin

Conversation

@ehartford

Copy link
Copy Markdown
Contributor

Fixes #1826. sdk.lock pins every LLVM SDK release + sha256; with build :deps installs and stamps the pin; a compiler link refuses a .deps SDK that is not the pin; seed-driver holds the workflow SDK pins to the lock. Also repins the nightly's linux-x86_64 SDK (asset replaced 2026-09-27; every linux-x86_64 leg failed since).

Verified: full build with SDKROOT=MacOSX27.0.sdk links stage and release against it with the pinned SDK. Draft until its battery is posted.

…efuses any other .deps SDK, seed-driver holds the workflow pins to it (#1826)

The arm64e.x1 backport (#1880) shipped in a republished darwin SDK, but
nothing told a checkout to use it: `with build :deps` kept whatever SDK a
tree once fetched (it returned early whenever libclang.a existed), and no
file named the SDK the tree is verified with. This host still linked a May
SDK whose ld64.lld cannot read Xcode 27's .tbd stubs.

- sdk.lock: `<asset>.version=` release, `<asset>=` archive sha256, plus the
  sidecar/manifest digests the nightly pins, for every SDK a workflow reads.
- :deps installs the host's pin, checks the download against the lock as
  well as the release sidecar, and stamps .deps/<sdk>/.with-sdk-pin; a lock
  bump refetches, an unchanged pin is a no-op. It prints with print_str:
  the pinned seed's comptime evaluator does not resolve the generic print.
- The link-metadata actions refuse a default .deps SDK whose stamp is not
  the pin, naming both and `with build :deps` (LLVM_PREFIX, which CI sets
  after checking the workflow pin, is taken as named).
- seed-driver refuses while any workflow SDK pin disagrees with sdk.lock.
- lock_value is the one key=value reader for seed.lock and sdk.lock,
  written without trim/index_of so the seed evaluates it at comptime.

The lock caught a second break: the linux-x86_64 SDK asset was replaced in
place on 2026-09-27 and the nightly's pin (c7747403) failed every
linux-x86_64 leg since; the nightly now pins the current asset, which
selfhost-linux builds the compiler with.

Verified: `src/main build` with SDKROOT=…/MacOSX27.0.sdk links stage and
release (-syslibroot MacOSX27.0.sdk) with the pinned SDK (415 s); the stale
.deps SDK is refused with the message above; seed-driver passes, and names
selfhost-linux.yml:41 when that pin is edited.
@ehartford

Copy link
Copy Markdown
Contributor Author

Stack #1928 battery GREEN on the top commit 3b9d06a (win-own-sdk) — covers all five layers.

  • gate rc=0 548 s; battery-checks rc=0 406 s (≈16 min end to end).
  • Every test ran fresh on the new compiler (0 cached): behavior 1520, native-compile-error 1560, native-spec 210, native-phase 69, internals 57, codegen 17, comptime-diff 6, lexer 7, parser 9.
  • fixpoint: stage2 == stage3 over all 16 units; drop-audit and move-audit green; :no-host-toolchain green.

The previous run (6cd934e) was red on internals-tests and cli-selfhost-build-w-tests; both fixed in the macOS layer (9abc92d file:// downloads, eba9cf2 lld link flags) and the stack re-folded.

Layers 1–4 are ready to merge. Layer 5 (#1931, Windows) stays draft until the Windows seed and the windows-gnu SDK are published and pinned (in progress).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Build: the lld stage link fails on Xcode 27's SDK (.tbd target arm64e.x1-macos) when SDKROOT points at it; comp_host_sdk_path trusts SDKROOT unchecked

1 participant