WIP: feat(macos): add a macOS build #2816

Draft
DuckNintendo wants to merge 114 commits from DuckNintendo/Longshot:macos/rebase-966 into main
Contributor

Type: feat · Risk: medium · Tested on: macOS arm64 · Needs: Windows and Linux, any GPU (and one GPU on the mesh compute fallback)

Summary

The macOS port rebased onto main 6f5f99fc and built with main's Rust builder and host API (version 57). The port's detail is in #966; this branch moves it onto main's builder, host API and simulated-turf work. The pre-merge head built and played; the merged head builds and is preparing its first start.

Testing

Tested: the pre-merge head (feda9160) built with the Rust builder and played from the title through New Game into the opening cutscene and gameplay on macOS arm64 with MoltenVK. The merged head (87085985) builds and links and runs its first-start preparation muted (HOS_AUDIO=0).

Still to test:

  • macOS arm64, merged head: finish the first start and play through a save, expecting the opening and gameplay (by hand; in progress).
  • Windows and Linux: host build (llvm-mingw/Linux) and a game run on one GPU each, expecting the same behavior (@Beanstalk or by hand).
  • Full test suite: the 532 failures here come from the stale longshot-966 test toolchain/headers (main has the same); mise run test with the dev tools, or CI, expecting a pass (by hand/CI).

Measurements

Nothing to measure against main on macOS: main does not build here. The port's earlier Mac measurement (32.79 frames/s, windowed 1280x752, 540 s) is in #966; this rebase changes the builder path and merges main, not the Mac draw path.

Risks

The renderer still links the system's libc++ while built with the newer one; the first-start stream paths read with C file I/O on macOS, and the sim-turf page is main's. The renderer's "network left out" path returns instead of throwing from a shader worker. Windows and Linux are untested here; the macOS build/run guide and the guide/UI review are still open.

Checklist

Ready for review

  • One topic, on current main; the title is a Conventional Commit.
  • Tested on my own PC, in the game for a change the game runs (pre-merge head; the merged head is in progress).
  • mise run test passes: 532 environment failures here from the stale test toolchain (main has the same); the merge's real test-source failures are fixed.
  • Measured against main, or Measurements says why there is nothing to measure.
  • No game files, build output or hand-edited generated files; third_party/ untouched; nothing GPL-incompatible.

When it applies

  • Host code builds on Windows (llvm-mingw) and Linux, with UTF-8 paths.
  • Docs updated: the switch rows are ported; the macOS build/run guide is still to write.
  • AI assistance recorded with Assisted-by: / Co-Authored-By: trailers.

Generated by opencode with deepseek-v4.1-flash-1017

**Type:** feat · **Risk:** medium · **Tested on:** macOS arm64 · **Needs:** Windows and Linux, any GPU (and one GPU on the mesh compute fallback) ## Summary The macOS port rebased onto main `6f5f99fc` and built with main's Rust builder and host API (version 57). The port's detail is in #966; this branch moves it onto main's builder, host API and simulated-turf work. The pre-merge head built and played; the merged head builds and is preparing its first start. ## Testing **Tested:** the pre-merge head (`feda9160`) built with the Rust builder and played from the title through New Game into the opening cutscene and gameplay on macOS arm64 with MoltenVK. The merged head (`87085985`) builds and links and runs its first-start preparation muted (`HOS_AUDIO=0`). **Still to test:** - macOS arm64, merged head: finish the first start and play through a save, expecting the opening and gameplay (by hand; in progress). - Windows and Linux: host build (llvm-mingw/Linux) and a game run on one GPU each, expecting the same behavior (@Beanstalk or by hand). - Full test suite: the 532 failures here come from the stale `longshot-966` test toolchain/headers (main has the same); `mise run test` with the dev tools, or CI, expecting a pass (by hand/CI). ## Measurements Nothing to measure against main on macOS: main does not build here. The port's earlier Mac measurement (32.79 frames/s, windowed 1280x752, 540 s) is in #966; this rebase changes the builder path and merges main, not the Mac draw path. ## Risks The renderer still links the system's libc++ while built with the newer one; the first-start stream paths read with C file I/O on macOS, and the sim-turf page is main's. The renderer's "network left out" path returns instead of throwing from a shader worker. Windows and Linux are untested here; the macOS build/run guide and the guide/UI review are still open. ## Checklist ### Ready for review - [x] One topic, on current `main`; the title is a Conventional Commit. - [x] Tested on my own PC, in the game for a change the game runs (pre-merge head; the merged head is in progress). - [ ] `mise run test` passes: 532 environment failures here from the stale test toolchain (main has the same); the merge's real test-source failures are fixed. - [x] Measured against `main`, or Measurements says why there is nothing to measure. - [x] No game files, build output or hand-edited generated files; `third_party/` untouched; nothing GPL-incompatible. ### When it applies - [ ] Host code builds on Windows (llvm-mingw) and Linux, with UTF-8 paths. - [ ] Docs updated: the switch rows are ported; the macOS build/run guide is still to write. - [x] AI assistance recorded with `Assisted-by:` / `Co-Authored-By:` trailers. Generated by opencode with deepseek-v4.1-flash-1017
Was: #454 (#454), branch mac/run-all at 264f826a7c (Sweep3, on main aa95d35f).

Its own commits, squashed:
- test: teach the game-free runner about macOS (45c54bc6f)
- test: skip main's new Windows-only guard check on macOS, and undo the SDK's vsnprintf macro in a fixture (264f826a7)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #477 (#477), branch mac/arm64-host at 0f021f29c1 (Sweep3, on main aa95d35f).

Its own commits, squashed:
- fix(runtime): compile host jumps and pause hints on macOS arm64 (0f021f29c)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #478 (#478), branch mac/guest-memory at dfb71ec850 (Sweep3, on main aa95d35f).

Its own commits, squashed:
- fix(runtime): preserve guest pages when discarding on macOS (b668404c8)
- fix(runtime): retain guest-page rounding in Darwin memory wrappers (e9c77d9f3)
- test(runtime): cut main's int hos_commit in the Darwin guest-memory test (7e737ce0f)
- test(runtime): follow main's HLE call counts in the Darwin guest-memory fixture (dfb71ec85)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #436 (#436), branch mac/fault-contexts at bccfd1c2e9 (Sweep3, on main aa95d35f).

Its own commits, squashed:
- fix(runtime): translate macOS fault contexts on both CPU routes (08940fb3d)
- test(runtime): keep Darwin fault checks native by default (7d7f99dcb)
- test(runtime): classify the fault bridge's fatal _exit in main's exit inventory (bccfd1c2e)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #437 (#437), branch mac/waits at beb8a2881a (Sweep3, on main aa95d35f).

Its own commits, squashed:
- fix(runtime): port Win32 waits and deadlines to macOS (2f05d007f)
- test(runtime): link Darwin waits into the pointer fixture (ef081688d)
- fix(macos): share address wait state through the executable (186a461c5)
- docs(runtime): describe the executable-owned macOS address-wait state (beb8a2881)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #438 (#438), branch mac/vk-admission at 681e37081d (Sweep3, on main aa95d35f).

Its own commits, squashed:
- feat(vk): add macOS Vulkan loader and device admission (6f34d00bc)
- test(vk): use semantic admission contracts (fdd161190)
- test(vk): follow main's LoadLibraryA and float-add choice in the admission fixture (3e088644f)
- test(vk): pin the admission ABI at main's version 23 and macOS 24 (4f4ca3c73)
- fix(macos): a window without Vulkan extensions ends as a clean exit, as main's exit inventory asks (681e37081)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #490 (#490), branch mac/darwin-host at 162a39dcd3 (Sweep3, on main aa95d35f).

It was stacked on #436, #437, #438, #454, #477, #478; their changes are the earlier commits here.

Its own commits, squashed:
- feat(macos): complete Darwin host lifecycle and diagnostics (71a9ed0bb)
- fix(macos): integrate profile consumers and joined-thread shutdown (f420761ab)
- docs(macos): describe Darwin profile symbol loading (04e40191a)
- test(macos): integration fix: cut the tagged HThread in the waits fixture (9c18e64c4)
- test(macos): integration fix: stub the kept startup in the display fixture (5f8d511e6)
- test(macos): integration fix: prof symbols run on macOS, not a skip (a1e73d31e)
- test(macos): the memory-notice fixture runs the Darwin query (f4d7aaf76)
- fix(macos): a failed swap query still shows the low-RAM notice (28ed288a2)
- test(macos): the Darwin LoadLibraryA keeps dlerror()'s text for hos_load_error (52faf1d3d)
- fix(macos): integration fix: main's process affinity for new threads is Linux-only (61ec2411b)
- fix(macos): the POSIX main's end after the game's thread marks the clean end, as main's exit inventory asks (162a39dcd)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #453 (#453), branch mac/build-flags at 8ca4bff7a4 (Sweep3, on main aa95d35f).

Its own commits, squashed:
- build(macos): discover dual-architecture toolchains and form Mach-O commands (499e3853a)
- test(macos): default real link fixtures to the process architecture (f6f6f042c)
- test(macos): isolate synthetic command paths from the test host (7c846ae91)
- build(macos): keep third_party/a64-kit as it is; nx2/darwin_toolchain.py makes its commands Mach-O (88054c966)
- build(macos): follow main's one-way renderer build and CPU target in the moved build code (a5b02633d)
- test(macos): the frozen Windows/Linux build arrays are main e090cc48's (c3009e01c)
- test: main's third-party objects test reads build.py with this PR's macOS names (8ca4bff7a)

Rebased onto main 7bacf846 (conflicts with #857 and #577, by hand): nx2/build.py keeps main's host-source line verbatim
(tests/test_no_webgpu.py matches it) with Darwin in its own clause before it; the WebGPU renderer job and have_wgpu go
(#577); executable_link loses its wgpu parameter and wgpu-native's import library and takes exe_resources() (#857) as
resources; nx2/make_game.py keeps main's BESIDE with this commit's DARWIN import, and the icon line takes #857's form with
(LINUX or DARWIN); tests/test_macos_build_flags.py and tests/build_flags_main.json drop wgpu-native the same way.

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #456 (#456), branch mac/control-sockets at fc2f104050 (Sweep3, on main aa95d35f).

Its own commits, squashed:
- fix(runtime): support control bridge Unix sockets on macOS (5fc3fe390)
- test(control): link the bridge's macOS socket helpers into test_oot_state_tap's fixture (fc2f10405)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #457 (#457), branch mac/control-quit at fe3e8c9178 (Sweep3, on main aa95d35f).

It was stacked on #456; their changes are the earlier commits here.

Its own commits, squashed:
- test(control): quit's parent waits for its bridge to listen, and a failed check ends the bridge it forked (fe3e8c917)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #476 (#476), branch mac/cache-files at 7e561fbb53 (Sweep3, on main aa95d35f).

Its own commits, squashed:
- fix(vk): preserve cache file reservations on macOS (7e561fbb5)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #480 (#480), branch mac/guest-16k at 657b780359 (Sweep3, on main aa95d35f).

It was stacked on #436, #478; their changes are the earlier commits here.

Merged with the topic's earlier commits by hand where they met (Consolidate-files/hand-resolutions.md).

Its own commits, squashed:
- fix(macos): serialize guest backing and native-page watch lifetimes (d7d999b92)
- fix(macos): retain pending watch faults across protection changes (a6a3e9e98)
- fix(macos): make the guest-memory changes Apple-only; Windows and Linux keep main's code (126d7bd67)
- docs(macos): describe the guest window's one owner, import pins and native-page watches (657b78035)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #492 (#492), branch mac/renderer-compile at 59f750aa38 (Sweep3, on main aa95d35f).

Its own commits, squashed:
- fix(macos): the renderer's last two files compile on Darwin (7ee5fd584)
- fix(macos): the debug tools are compiled on Darwin too (82b2d6606)
- test(macos): the debug tools check reads hos_oot_player_seen's body too (59f750aa3)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #511 (#511), branch mac/crash-records at c4d95017aa (Sweep3, on main aa95d35f).

It was stacked on #436; their changes are the earlier commits here.

Its own commits, squashed:
- fix(runtime): take the macOS report run id from getentropy (d3e86ddd7)
- fix(runtime): read crash-record memory and modules without /proc on macOS (aa039e142)
- test(runtime): build the crash-record fixture on macOS (adebf9dbb)
- test(runtime): link the macOS fault bridge into the crash-record fixture (c4d95017a)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #516 (#516), branch mac/longshot-ctl-darwin at 3b9d3cfa2a (Sweep3, on main aa95d35f).

Its own commits, squashed:
- fix(control): tell macOS processes apart by their sysctl start time (56f4ca876)
- test(control): compare launch's data folder with the resolved run folder (3b9d3cfa2)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #491 (#491), branch mac/renderer-correctness at 695f6859dc (Sweep3, on main aa95d35f).

It was stacked on #438, #480; their changes are the earlier commits here.

Its own commits, squashed:
- fix(macos): pin renderer imports through final resource ownership (db82a0f23)
- test(macos): cut the non-Apple Pool and import route in three more fixtures (6cee76eb1)
- fix(vk): drain the recorder before startup rollback destroys the allocator (18c05be52)
- test(macos): follow main's #324 and #250 in the Darwin renderer fixture (c099f5da6)
- test(vk): follow the moved Pool in test_mirror_gpu_only's cut (165bf7e61)
- fix(macos): the import pin callbacks are macOS host API version 25 (fa691b55b)
- fix(macos): vk_memory.cpp compiles on macOS: #324's evicted_pools declaration is not Apple's (695f6859d)

Rebased onto main 7bacf846 (conflicts with #223, by hand): gpu/vk/vk_memory.cpp declares main's evicted_import_bytes after
this commit's macOS evicted_pools #endif, and imports_give_back keeps main's accounting line before this commit's
destroy_import(p) (which frees the pool's pieces as main's lines did).

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #642 (#642), branch mac/gpu-budget at 09978824a0 (Sweep3, on main aa95d35f).

Its own commits, squashed:
- feat(vk): read the Mac's system memory for the renderer (gpu/vk/system_memory.h) (ba1952096)
- fix(macos): on unified memory the GPU's allowance is what the Mac's RAM leaves, not Metal's working set (632636ee0)
- fix(macos): vk_work.h stays vk_vma.cpp's last include (0e63a1dc1)
- fix(macos): the unified budget reads the system's memory at its first ask (5240eade7)
- docs(macos): RX_VK_UNIFIED_BUDGET in the switch table (09978824a)

Rebased onto main 7bacf846 (conflict with #223, by hand): texture_frame's staging arenas go when kept + size passes this
commit's keep_now, or main's stale time (5 s under Linux memory pressure) passes, or main's Linux pressure begins; on macOS
main's Linux pressure never turns on, and keep_now is keep off macOS.

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #653 (#653), branch mac/metal-cache at db50cf3d26 (Sweep3, on main aa95d35f).

It was stacked on #438; their changes are the earlier commits here.

Its own commits, squashed:
- feat(macos): Metal's shader cache in a folder the caller names (db50cf3d2)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #654 (#654), branch mac/kosmickrisp at 9d34f9a1c8 (Sweep3, on main aa95d35f).

It was stacked on #438, #479; their changes are the earlier commits here.

Merged with the topic's earlier commits by hand where they met (Consolidate-files/hand-resolutions.md).

Its own commits, squashed:
- feat(macos): ship the Vulkan loader with KosmicKrisp and MoltenVK, chosen at startup (fbd562421)
- test(macos): the driver package fixture takes the architecture and SDK from darwin_toolchain (3472d670c)
- fix(macos): type the driver manifest's ICD record for Pyright (296b5347b)
- fix(macos): MoltenVK is the default Vulkan driver on every macOS (86c017e42)
- test(macos): the display fixture counts longshot_env.txt's loads on Apple only (9d34f9a1c)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #643 (#643), branch mac/mvk-push at ca17df3be6 (Sweep3, on main aa95d35f).

Its own commits, squashed:
- fix(macos): storage buffer tables get descriptor sets on MoltenVK (ca17df3be)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #644 (#644), branch mac/mvk-sizes at f08eb70206 (Sweep3, on main aa95d35f).

It was stacked on #643; their changes are the earlier commits here.

Its own commits, squashed:
- fix(macos): programs reading storage buffer lengths get descriptor sets on MoltenVK (f08eb7020)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #645 (#645), branch mac/mvk-rwtex at b8b1ba998a (Sweep3, on main aa95d35f).

It was stacked on #644; their changes are the earlier commits here.

Its own commits, squashed:
- fix(macos): stages with more than 8 read_write textures get descriptor sets on MoltenVK (b8b1ba998)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #646 (#646), branch mac/mvk-pushlimits at 374c55a031 (Sweep3, on main aa95d35f).

It was stacked on #645; their changes are the earlier commits here.

Its own commits, squashed:
- fix(macos): stages past a Metal function's buffer, texture or sampler table get descriptor sets on MoltenVK (6c9e3c9fa)
- fix(macos): MoltenVK's descriptor sets are update-after-bind layouts, within Vulkan's limits for them (3e7d8d3d3)
- test(vk): recording_admission's device stub has the fixes make_pool now reads (374c55a03)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Every scan down vk_memory.cpp's import table by start (pool_lookup's
covering import and merge plan, bg_drain, prefetch_chunks,
import_in_background, memory_note_gpu_write and memory_guest_imported)
stopped once an import ended more than 1 GiB below its address, on the
belief that no import is larger than that. pool_lookup's own merge escape
leaves an import above 1 GiB over the smaller ones inside it ("left
overlapping"), and the device allows imports up to max_import_size: a scan
stopped at a small import inside a large one, missed the large one, and
the same bytes were imported again, two memories over the same bytes.

import_reach.h counts the live imports by span class; its bound is above
every live span, within twice the largest. imported_add and imported_take,
now the table's only ways in and out, keep the count. A scan stops only
where no import further down can reach its address, so it also stops
sooner than before when the imports are small. The covering-import checks
in pool_lookup and import_in_background look past the last import at or
below the range for the same reason.

Tests: test_import_reach.py runs the actual scans with a 4 GiB import over
a 16 MiB chunk, left by the merge escape (imports are recorded ranges: no
payload, no Vulkan, no game). Its lookup, query, note, drain, background
and prefetch cases fail on main 5e072fc8 and pass here, and a source check
keeps every change to the table in the two helpers. test_import_windows
runs pool_lookup with the helpers; test_mirror_gpu_only names the new
publication point.

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #647 (#647), branch mac/seg-plan at 52def6832c (Sweep3, on main aa95d35f).

Its own commits, squashed:
- feat(vk): plan where an oversize guest span is cut into import segments (601c00ccd)
- feat(vk): let the segment planner add segments that pay for themselves (52def6832)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #648 (#648), branch mac/seg-shader at 9b73e82942 (Sweep3, on main aa95d35f).

Its own commits, squashed:
- feat(vk): descriptors bound as pieces in the SPIR-V back end and program variants (1f9183c2a)
- fix(vk): MslArrayPtr: no pointer into a storage buffer array is passed to a function (9b73e8294)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #649 (#649), branch mac/texel-codec at c5cbd39d26 (Sweep3, on main aa95d35f).

It was stacked on #648; their changes are the earlier commits here.

Its own commits, squashed:
- feat(vk): texel codecs in the SPIR-V back end and program variants (c5cbd39d2)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #658 (#658), branch mac/renderer-core at f8d4e51ad5 (Sweep3, on main aa95d35f).

It was stacked on #431, #491, #647; their changes are the earlier commits here.

Merged with the topic's earlier commits by hand where they met (Consolidate-files/hand-resolutions.md).

Its own commits, squashed:
- fix(vk): join #431's import table helpers with #491's macOS Pool (a1d08d92a)
- fix(macos): import NOACCESS guest pages and name a missing audio service (e6e92a90d)
- feat(vk): admit an operation's guest buffers before it binds them (alias isolation, macOS) (a27bee681)
- feat(vk): import a span past one device allocation as segments (SegMem, alias isolation) (dd4f13047)
- test(vk): follow the renderer-core merge's moved code in three extractions (6e77a383f)
- fix(vk, macos): admit a parallel batch's uniform updates in order, and keep its own updates out of its handoff (3fbfca08d)
- fix(vk, macos): keep every byte the page table reached mapped when an admission retires imports (616eacb83)
- fix(vk, macos): one view per byte of an Apple spare backing, and no endless retry of a failed view (04e00832b)
- fix(vk, macos): bg_drain publishes no background import over this epoch's retired memory or across a domain (a3913a646)
- fix(vk, macos): admission merges no import past 1 GiB again, so mirror_make can still mirror it (b8d16a20b)
- fix(vk, macos): a segment keeps a crossing import's bytes as leftovers clipped at the cuts, not as whole segments (aab3fd8a6)
- fix(vk, macos): each new import over a retired import's bytes inherits its share of that import's VRAM mirror (73bbb89ad)
- test(vk): the admission fixtures follow main's #250 sparse mirrors (6fa302cce)
- fix(vk, macos): the actor motion's resolver follows #59: a pose read at its draw is not copied (e0941ccc0)
- test(vk): test_split_ub_flush follows flush_ub_updates' end parameter (f8d4e51ad)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #662 (#662), branch mac/seg-contract at 0401eeb237 (Sweep3, on main aa95d35f).

It was stacked on #649, #658; their changes are the earlier commits here.

Its own commits, squashed:
- feat(vk): the segmented consumers' frozen contract (C0) (0401eeb23)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #663 (#663), branch mac/seg-consumers at 5400f1a0b6 (Sweep3, on main aa95d35f).

It was stacked on #645, #662; their changes are the earlier commits here.

Its own commits, squashed:
- feat(vk): texel codecs' views, texel piece views, null-descriptor stand-ins and presence words (TexelDesc, L3) (da741bdb2)
- test(vk): the texel ownership fixture names the case that failed (39d6490dd)
- feat(vk): SegBind's descriptor core, gathers and arena (L1) (7d5d51276)
- fix(vk): a draw reusing its descriptors drops an earlier build's refusal (SegBind) (7104d8324)
- test(vk): SegBind's gathers and notes fixtures, its parts of three checks, and its docs section (31d52778f)
- test(vk): test_set_for_tables reads its cut from --source (4462202ff)
- test(vk): test_mesh_fallback's topology anchor follows draw()'s `plain` (0f743f0b9)
- test(vk): test_set_for_lengths' layout fixture takes SegBind's seg_layout_count and presence_words (3b5f3b477)
- feat(vk): SegXfer, the transfer consumers of a range across a segment's cut (L2) (3200ff464)
- fix(vk): dispatch()'s compute-variant path (#252) names SegBind's pre-seam `plain` (c13540fc5)
- test(vk): the seg_gathers fixture stubs #162's rec::OwnSlot (8089dc409)
- test(vk): SegXfer's fixture and resolver sites follow #59's actor motion (1ab6beb2b)
- test(vk): SegXfer's gpu_write checks follow #329's ordered inline writes (5400f1a0b)

Rebased onto main 7bacf846 (conflicts with #231 and #403, by hand; #403 by the owner's decision: main's generic dummy views
stay on every device without nullDescriptor, the typed stand-ins on Apple only):
- RecordingRes keeps main's FlatMap c1_at (#231) with this commit's arena fields, and draw_begin_recording resets the arena
  and calls main's c1_at.reset().
- make_dummies is main's (#403) unchanged; the stand-ins move to make_stand_ins (Apple), called once beside
  null_storage_make, before make_dummies. NullDummies carries main's generic view[] (dummies stays one object).
- build_descriptors binds a typed stand-in first where they are made, then main's generic view where none is (sampled
  images as main's existing line did; storage images as #403's line does), so nothing is bound VK_NULL_HANDLE without
  nullDescriptor.
- The cut-out fixtures that stub null_storage_make stub make_stand_ins too.

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #674 (#674), branch mac/null-shader at b7683077e6 (Sweep3, on main aa95d35f).

It was stacked on #663; their changes are the earlier commits here.

Its own commits, squashed:
- feat(vk): null-descriptor emulation in the SPIR-V back end (NullShader, L4) (71003696f)
- docs(vk): NullShader: image and image buffer arrays share a known gap (17667bea3)
- fix(vk): NullShader: two source-cutting checks the wip commit broke (f53eda6cd)
- fix(vk): MslArrayPtr's NullShader half: a descriptor bound whole calls its loop function, and the loops' CPU runs (b7683077e)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #675 (#675), branch mac/tex-read-order at c5c6a853a8 (Sweep3, on main aa95d35f).

It was stacked on #674; their changes are the earlier commits here.

Its own commits, squashed:
- fix(vk): TexOrder: store each image read in place on MoltenVK (fb51f7807)
- test: test_amd_subgroup_profiles: the MoltenVK driver id in make_profile's stand-in (8d5fc5373)
- fix(vk): TexOrder: an image memory barrier before each image write and atomic on MoltenVK (c5c6a853a)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #676 (#676), branch mac/msl-depth at f8e18c953b (Sweep3, on main aa95d35f).

It was stacked on #675; their changes are the earlier commits here.

Its own commits, squashed:
- fix(macos): MoltenVK's Metal source nests no deeper than 32 forwarded instructions (71d2498c4)
- test(vk): the subgroup profile fixture knows MoltenVK's driver id (f8e18c953)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #686 (#686), branch mac/rosetta-import at 6ec9629e59 (Sweep3, on main aa95d35f).

It was stacked on #658; their changes are the earlier commits here.

Its own commits, squashed:
- fix(macos): Rosetta host imports: whole hardware pages, refused imports asked again only when their backing changes (ae91338ae)
- fix(macos): the backing generation is Apple host API version 26, after #491's import pins at 25 (6ec9629e5)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #692 (#692), branch mac/msl-depth2 at a67e1934ec (Sweep3, on main aa95d35f).

It was stacked on #676; their changes are the earlier commits here.

Its own commits, squashed:
- fix(macos): the nesting bound counts only the reads SPIRV-Cross certainly makes (a67e1934e)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #693 (#693), branch mac/compile-gaps at 5ceed495b2 (Sweep3, on main aa95d35f).

It was stacked on #692; their changes are the earlier commits here.

Its own commits, squashed:
- fix(vk): bound the control-flow nesting of SPIRV-Cross's Metal source on MoltenVK (46b5810a9)
- perf(vk): parse the module in place when the scope bound has nothing to move (5ceed495b)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #694 (#694), branch mac/subgroup-vertex at a3e8a51faf (Sweep3, on main aa95d35f).

It was stacked on #676; their changes are the earlier commits here.

Merged with the topic's earlier commits by hand where they met (Consolidate-files/hand-resolutions.md).

Its own commits, squashed:
- fix(vk): MoltenVK's vertex stages run the guest's warp operations as one-lane warps (a2b3b0578)
- test(vk): test_subgroup_vertex: the base tree's own checks unprinted, and one failure message per cause (e20482fa9)
- test(vk): test_subgroup_vertex: SPIRV-Cross drops a subgroup barrier in a vertex function (a3e8a51fa)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #695 (#695), branch mac/spv-size at 43d1a23420 (Sweep3, on main aa95d35f).

It was stacked on #676; their changes are the earlier commits here.

Its own commits, squashed:
- feat(vk): RX_VK_SPV_PROFILE, what the big SPIR-V modules are made of (3d7b1f5f6)
- docs(vk): spirv_profile.h's store names where the line is printed (ebf1854b4)
- docs(vk): RX_VK_SPV_PROFILE's text names the slow compile line as the precompile hand-off's (43d1a2342)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #696 (#696), branch mac/gm-loop at 231115f14c (Sweep3, on main aa95d35f).

It was stacked on #694, #695; their changes are the earlier commits here.

Merged with the topic's earlier commits by hand where they met (Consolidate-files/hand-resolutions.md).

Its own commits, squashed:
- feat(vk): MoltenVK and KosmicKrisp search storage buffer tables in loops in every global memory fallback (39a40fed6)
- test(vk): gm_loop_ir --gpu: the loop forms first, then the written-out ones, smaller first (99616b7ab)
- test(vk): stub table_loops_on where make_profile is compiled cut out (231115f14)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #697 (#697), branch mac/local-mem-buffer at a526c34c9f (Sweep3, on main aa95d35f).

It was stacked on #696; their changes are the earlier commits here.

Its own commits, squashed:
- feat(vk): MoltenVK zeroes local memory at computed offsets by a loop, not a written-out initializer (a526c34c9)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #698 (#698), branch mac/kk-tex-order at 8a3d7db0ce (Sweep3, on main aa95d35f).

It was stacked on #654, #675; their changes are the earlier commits here.

Its own commits, squashed:
- fix(macos): TexOrder's stored image reads on KosmicKrisp too (27d566b45)
- test(macos): the Apple drivers' check names the fixes this tree makes (8a3d7db0c)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #787 (#787), branch mac/giant-shape at 96b51b55b5 (Sweep3, on main aa95d35f).

It was stacked on #697; their changes are the earlier commits here.

Its own commits, squashed:
- test: giant mesh fallbacks' shape through the real SPIR-V back end (tests/giant_shape_ir.cpp) (96b51b55b)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
The Mac-only part of fix/async-safe-frees-i40 (c151fcea, MvkAsyncFix's F5) that #788 does not carry, because
null_dummies_make (#663, macOS: MoltenVK has no nullDescriptor) exists only on the macOS stack. The stand-in images' clear
waits 5 s for its fence; when that wait ran out, the fence and the command pool were destroyed while the GPU might still be
clearing (a destroyed pool under a pending command buffer). Now a clear submitted and not seen done in 5 s is waited for
without a limit first, as #788 does for the read-back. The clear is still reported as not done in time (the "may read
garbage" line), as before.

tests/test_null_dummies.py: case make-slow-clear (the fixture's fence wait runs out once): one unbounded wait after the 5 s
one, before the fence and the pool are destroyed. Fails before this commit (one wait, none unbounded), passes after, on arm64
and x86_64 under Rosetta.

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
In this topic #698 (KosmicKrisp's TexOrder, its Apple drivers' fixture in test_vendor_fixes) meets #694/#696
(SubgroupVertex: make_profile reads dev.subgroup_stages and Shader::Stage) and #697's two switches (GmLoop's
table_loops_on, LocalMemBuffer's local_zero_loop_on), and test_subgroup_vertex's stub meets KosmicKrisp's
VK_DRIVER_ID_MESA_KOSMICKRISP in make_profile. Each member passes at its own Sweep3 head; at the topic's tip the
fixtures did not build. This takes I41's fixes 02b10861 and 560923891's stub line:
- test_subgroup_vertex: the KosmicKrisp driver constant (28, the Vulkan headers' value);
- test_vendor_fixes' Apple drivers' fixture: subgroup_stages (all stages), stage.h, and table_loops_on and
  local_zero_loop_on stubs; its columns are unchanged.

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
(cherry picked from commit 02b108611 and the local_zero_loop_on line of 560923891)
The port 55cfa887 (a stand-in clear not done in 5 s is waited for, without a limit, before its fence and command pool are
destroyed) put two lines in null_dummies_make that Windows and Linux compiled too, though they never run there:
null_dummies_make returns at once off Apple (null_dummies_on() is false: kApple). The two lines now sit inside
#if defined(__APPLE__), the file's gate for its other macOS-only lines, so Windows and Linux compile none of the port:
vk_texture.cpp off Apple (unifdef -U__APPLE__) is the same as at the port's parent 1bf322f4, and on macOS the code is
55cfa887's.

tests/test_null_dummies.py cuts null_dummies_make with the gate and builds it on macOS, where __APPLE__ is defined; its
make-slow-clear case is unchanged.

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #677 (#677), branch mac/mode-census at d2fd7a90ff (Sweep3, on main aa95d35f).

It was stacked on #663; their changes are the earlier commits here.

Merged with the topic's earlier commits by hand where they met (Consolidate-files/hand-resolutions.md).

Its own commits, squashed:
- feat(vk): count polygon modes and restart-off strip draws on Apple, log-only (d2fd7a90f)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #678 (#678), branch mac/mvk-temp at 989a6423d9 (Sweep3, on main aa95d35f).

It was stacked on #677; their changes are the earlier commits here.

Merged with the topic's earlier commits by hand where they met (Consolidate-files/hand-resolutions.md).

Its own commits, squashed:
- fix(macos): bind a direct draw's 8-bit indices with their size on MoltenVK (ca6b27fdd)
- docs(macos): RX_VK_INDEX8_SIZE in the switch table (989a6423d)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #679 (#679), branch mac/count-draws at 2028d598e6 (Sweep3, on main aa95d35f).

It was stacked on #677; their changes are the earlier commits here.

Merged with the topic's earlier commits by hand where they met (Consolidate-files/hand-resolutions.md).

Its own commits, squashed:
- fix(macos): draw count draws through a record rewrite where the device has no drawIndirectCount (4d9de1004)
- fix(macos): the count draw report in its own block; SegBind's fixture cuts the rewrite (ce7388bf0)
- fix(macos): buffer updates copied from the recording's stream on MoltenVK (574597e08)
- fix(macos): the count-draw rewrite on macOS only; Windows and Linux give count draws to the driver as before (791fe3a75)
- docs(macos): RX_VK_COUNT_REWRITE in the switch table (e4a7ab285)
- test(vk): test_inline_write_order (main's, #329) has gpu_write's cmd_update_buffer (2028d598e)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #680 (#680), branch mac/drawid-direct at 6c0204eb98 (Sweep3, on main aa95d35f).

It was stacked on #679; their changes are the earlier commits here.

Merged with the topic's earlier commits by hand where they met (Consolidate-files/hand-resolutions.md).

Its own commits, squashed:
- fix(macos): direct draws that read the draw index drawn as one indirect record on MoltenVK (4876f2615)
- fix(macos): tessellated direct draws reading the draw index counted, not logged as errors (32a83be13)
- test(macos): the three recording fixtures stand in stream_usage (6c0204eb9)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #691 (#691), branch mac/moltenvk-main at ebd6b127e2 (Sweep3, on main aa95d35f).

It was stacked on #654, #679; their changes are the earlier commits here.

Merged with the topic's earlier commits by hand where they met (Consolidate-files/hand-resolutions.md).

Its own commits, squashed:
- docs(macos): a MoltenVK built from main as the MoltenVK input (546102abe)
- docs(macos): MoltenVK main 5189f8de with the argbuf-slots patch as the recommended MoltenVK input, and how to build it (ebd6b127e)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #701 (#701), branch mac/fan-key at cd1ce0b214 (Sweep3, on main aa95d35f).

It was stacked on #680; their changes are the earlier commits here.

Merged with the topic's earlier commits by hand where they met (Consolidate-files/hand-resolutions.md).

Its own commits, squashed:
- feat(macos): count fans against their pipelines' static topology on MoltenVK, log-only (773588160)
- fix(macos): fans keyed apart from the other triangle topologies on MoltenVK (cd1ce0b21)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #702 (#702), branch mac/fan-indirect at d7878c9d1a (Sweep3, on main aa95d35f).

It was stacked on #701; their changes are the earlier commits here.

Merged with the topic's earlier commits by hand where they met (Consolidate-files/hand-resolutions.md).

Its own commits, squashed:
- feat(macos): count indirect fans and their records on MoltenVK, log-only (927ed3de1)
- fix(macos): an indirect fan of more than one record drawn a call a record on MoltenVK (3a743b80f)
- test(macos): the indirect fans' census checked right after FanKey's, not as draw()'s last statement (62a089ad7)
- test(macos): the segment gathers' fixture stands in FanIndirect's way and split (d7878c9d1)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #703 (#703), branch mac/provoking-first at 73d4bc9bd4 (Sweep3, on main aa95d35f).

It was stacked on #701; their changes are the earlier commits here.

Merged with the topic's earlier commits by hand where they met (Consolidate-files/hand-resolutions.md).

Its own commits, squashed:
- feat(macos): count the draws that depend on the provoking vertex where the device has no provokingVertexLast (8276aa94d)
- fix(macos): direct draws that depend on the provoking vertex drawn with each primitive's last vertex first, without provokingVertexLast (ac8416c59)
- fix(macos): adjacency draws that depend on the provoking vertex drawn as plain lists with each primitive's last vertex first (1977f19f5)
- fix(macos): the mesh fallback's draws that depend on the provoking vertex drawn with each primitive's last corner first (6493717b6)
- fix(macos): lines that depend on the provoking vertex counted only, not reversed (e702fd96e)
- fix(macos): a converted draw's list written into the stream of the recording it is drawn in (4f9891106)
- test(macos): draw()'s fixtures stand in ProvokingFirst's list and count its index binds (e42bf6e87)
- test(macos): test_fan_key reads draw()'s count lines with ProvokingFirst's count on them (531fd13ec)
- test(macos): a converted fan is drawn with a pipeline built as a list under FanKey's key (523d0696e)
- fix(macos): the provoking-vertex count and lists on macOS only; Windows and Linux record as before (73d4bc9bd)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Hand resolution on topic/draw-path, where #702 (FanIndirect) met #703 (ProvokingFirst), siblings on #701 that only this topic
combines. test_fan_indirect (#702) cuts draw()'s indirect block up to "} else if (d.indexed) {"; #703 puts its own branch,
"} else if (pv.made) {" (the list written into the stream and drawn as an indexed draw), between the two, so the cut took it in and
the fixture no longer built (pv, ProvokingWrite, game_topo, drawid_direct undeclared). The cut now ends at draw()'s next branch,
whichever it is, as Integration 37's eb4d02046 has it (its tests/test_fan_indirect.py line only). The check keeps what it requires;
no source changes.

test_fan_indirect: failing at 5efbe9d8 on arm64 and x86_64, passing with this commit; passing at #702's Sweep3 head d7878c9d.

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Hand resolution on topic/draw-path. #701's resolution (chain commit 21e6ec79) placed draw_fan_census_report after #678's
draw_index8_report and dropped the closing } of draw_index8_report, so gpu/vk/vk_draw.cpp stopped compiling from there ("function
definition is not allowed here" at draw_fan_census_report, then every later definition), on arm64 and x86_64, at every commit from
21e6ec79 to this one. The } goes back after the report's logf, as Integration 41 (78ec1c47, vk_draw.cpp 5087) has it, without
#782's widen8_report line (topic mac-perf). No other change.

Found by the whole-file compile of vk_draw.cpp at this topic's tip and at the topics on it.

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
- feat(vk): count quad draws, and the indirect ones left out (log-only) (08878e8c7)
- fix(vk): draw indirect quad draws, with and without a count, on every driver (30c4461d3)
- fix(vk): an indexed quad expansion's workgroup bound saturates (5fa122654)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
- feat(vk): count mesh draws by kind and what the mesh fallback cuts (log-only) (435c47d47)
- feat(vk): draw mesh count draws on the compute fallback (092afd495)
- fix(vk): the mesh fallback's records area grows on demand (17cace138)
- test(vk): six fixtures follow the mesh counters, count draws and growing area (02db49808)
- fix(vk): the mesh count draws bind their stages without RX_VK_LMEM_LOG's hook, which this base lacks (b41a03a9a)

Rebased onto main 7bacf846 as a plain commit on #705's (the topic merged #705 and #707 before; both are folded into this
PR): gpu/vk/VULKAN.md takes the topic merge 3d3939ad's resolution of #705 with #707, replayed by git merge-file (clean).
log_frame_stats keeps its closing brace, which that merge lost (d99221c42 put it back).

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #706 (#706), branch mac/indirect-quads at 6e6bc8d921 (Sweep3, on main aa95d35f).

It was stacked on #705; their changes are the earlier commits here.

Its own commits, squashed:
- fix(macos): quads provoke the same corners where the first vertex provokes (6e6bc8d92)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #708 (#708), branch mac/mesh-provoking at d24ecc70ec (Sweep3, on main aa95d35f).

It was stacked on #703, #707; their changes are the earlier commits here.

Merged with the topic's earlier commits by hand where they met (Consolidate-files/hand-resolutions.md).

Its own commits, squashed:
- fix(vk): the mesh fallback's rotation kept to what its list covers; the indirect quads counted for the provoking vertex; five checks follow (3a7b258ec)
- test: test_seg_xfer's fixture stands in fallback_draw_area (87f575c40)
- fix(macos): the mesh fallback's rotation follows the count draws and the growing records area (70686bc10)
- fix(macos): the mesh fallback's rotation decided and counted on macOS only, as ProvokingFirst's other gates (4800449a5)
- fix(macos): a rotated mesh fallback draw's area is cut only when its rotation list covers fewer corners than it holds (d24ecc70e)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Hand resolution on restack/fix/indirect-quads, where #705 (IndirectQuads) meets topic/draw-path (#678, #680, #701, #703), as
Integration 36's 74da414a and Integration 37's eb4d02046 resolved it (only their hunks at this level: no PerfInstr hook, no mesh
fallback part).

- gpu/vk/vk_draw.cpp: #705's indirect quad draw is a sixth draw site in draw(). Its count gains ProvokingFirst's provoking_note
  (#703) and FanKey's census_fan_draw (#701), as the other sites and the direct quads' have them. Both return at once off Apple and
  off MoltenVK (provoking_first() is false off __APPLE__; census_fan_draw checks VK_DRIVER_ID_MOLTENVK): log-only counts, nothing
  recorded or drawn changes on any driver. Off Apple the two calls are the token change.
- tests/test_quad_draws.py (#705's): the direct quad draw as topic/draw-path has it, DrawIdDirect's record (rq) drawn from its
  words, then the count with provoking_note, then quad_drawn.
- tests/test_provoking_first.py (#703's): six census_draw sites, each with provoking_note (was five).
- tests/test_fan_key.py (#701's): three non-mesh sites of six counts (was two of five).
- tests/test_index8_bind.py (#678's): draw()'s indirect and direct branches found at a line's start (#705's rewrite gate holds a
  deeper "if (d.indirect) {" line first).
Each check keeps what it requires; none is dropped.

test_quad_draws, test_provoking_first and test_index8_bind failed at the merge before this commit; with it they pass, with
test_fan_key and test_fan_indirect, on arm64 and x86_64.

Rebased onto main 7bacf846 as a plain commit (it sat on #705's restack branch after a merge of topic/draw-path):
tests/test_provoking_first.py takes the topic merge 174d02096's text, replayed by git merge-file (clean); the whole tree
equals that merge replayed over its first parent.

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Hand resolution on restack/fix/mesh-count, where #707 (MeshCountDraws) meets #680 (DrawIdDirect), a pair this restack first
combines. #707 declares BuiltIn DrawIndex for a stage loading DrawID except a mesh fallback's task or mesh stage (a GLCompute stage,
its draw index pushed); test_drawid_direct (#680's) pinned the old condition and failed ("spirv_emit_context.cpp declares
DrawIndex other than for a stage loading DrawID and the mesh-first task stage") at this restack and at topic draw-path-quads-mesh,
on arm64 and x86_64. It now pins the new one (DrawIdDirect's direct draws never come from those stages), and
program_reads_draw_index's comment says so: Integration 36's b4732392, its test_drawid_direct hunk and that comment only (its
perf_lines parts belong to topic mac-perf). No code change: the comment is the only vk_draw.cpp change.

test_drawid_direct: failing before this commit, passing with it, on arm64 and x86_64.

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #704 (#704), branch mac/perf-instr at 040b840d97 (Sweep3, on main aa95d35f).

It was stacked on #679; their changes are the earlier commits here.

Merged with the topic's earlier commits by hand where they met (Consolidate-files/hand-resolutions.md).

Its own commits, squashed:
- feat(vk): log-only frame cost lines, a GPU timeline and the bench's A/B exactness arm, all off by default (43d7e8e89)
- test(vk): test_inline_write_order (main's, #329) includes perf_lines.h for full_barrier's bench arm (040b840d9)

Rebased onto main 7bacf846 (conflicts with #769 and #443, by hand): vk_replay.cpp includes main's hold_gpu.h and this
commit's vk_perf.h; replay() notes the op for PerfInstr (draw_perf_op) before main's part end right before a plain draw
(#443's split_part); maybe_split became part_ends_before_draw and split_part in main, and this commit's
perf_lines::why(PassEnd::PartSplit) sits in split_part after its refusals, where the part really ends.

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #780 (#780), branch mac/load-clear at 12fe15f62d (Sweep3, on main aa95d35f).

It was stacked on #704; their changes are the earlier commits here.

Merged with the topic's earlier commits by hand where they met (Consolidate-files/hand-resolutions.md).

Its own commits, squashed:
- perf(macos): a pass's leading whole clears as its attachments' LOAD_OP_CLEAR on MoltenVK (MacPerf #7) (66b6b0234)
- fix(macos): load_clear's kept operations as a set of bits, its device line from the vendor fixes (1b86d46b2)
- fix(vk): LoadClear off by default (mirrors macos/integrated 2b4b7b8e, I40) (12fe15f62)

Rebased onto main 7bacf846 (conflict with #443, by hand): in replay() the held pass is settled before main's part end right
before a plain draw (split_part), so a part never ends with a held pass.

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #782 (#782), branch mac/widen8 at 8b3eb471fb (Sweep3, on main aa95d35f).

It was stacked on #678, #703, #780; their changes are the earlier commits here.

Merged with the topic's earlier commits by hand where they met (Consolidate-files/hand-resolutions.md).

Its own commits, squashed:
- test: test_perf_lines reads draw()'s counted draws with ProvokingFirst's count line and FanKey's census (610309546)
- perf(macos): LS widens a pass's 8-bit indices itself on MoltenVK (8115c3272)
- fix(macos): restart-off 8-bit draws fetch 0xFF as vertex 255 on MoltenVK, as NVN does (84cd6d0c3)
- test: test_resolver_coverage lists widen8_before_draw's index binding (bf07ead64)
- fix(vk): one pass_keeps for LoadClear and Widen8; the widening checked right before a held begin (fe92e5378)
- fix(vk): Widen8's look ahead off by default; INDEX8_RAW stays on (mirrors macos/integrated 2b4b7b8e, I40) (8b3eb471f)

Rebased onto main 7bacf846 (after topic/draw-path's 67fd90bc closed draw_index8_report, which this commit's base lacked):
widen8_report(when) stays the function's last line, before that brace.

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #783 (#783), branch mac/mesh-batch at 7a196c0a99 (Sweep3, on main aa95d35f).

It was stacked on #708, #782; their changes are the earlier commits here.

Merged with the topic's earlier commits by hand where they met (Consolidate-files/hand-resolutions.md).

Its own commits, squashed:
- fix(vk): mesh count draws' pass end said MeshFallback; two checks follow mesh-count's moves (3d33cd202)
- vk: batch the mesh fallback's draws of a pass on MoltenVK (MeshBatch) (e5450f384)
- vk: MeshBatch's per-thread batch as a TLS_OBJECT (210a1f9fb)
- test: LoadClear, Widen8 and MeshBatch checked together at a pass's begin and end (7a196c0a9)

Rebased onto main 7bacf846 (conflict with #231, by hand): draw_begin_recording empties c1_at with main's reset() (its
array kept) before this commit's mesh_batch_recording_begun(r), and tests/test_mesh_batch.py asks for that reset();
main's tests/test_flat_map.py requires it.

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
StreamRoom (reports/2026-11-15-stream-room.md). Run #36 (I40) left out 11,756 direct draws that depend on the provoking vertex
("no room for its list in the stream of the recording it was drawn in", count 4, not indexed; vk_draw.cpp:11764), I39's
MeshBatch-on runs 122-174 each (:11747, the same line). The stream was never short: the most a recording held was 292 KB of
2 MB and none grew. ProvokingFirst decides the list with the recording's command buffer, then draw() redirects the open mesh
batch's draws into its segment (mesh_batch_cmd), and provoking_write asked for cmd == rec_cmd: every list draw recorded in a
batch's pass was left out, its pipeline already the list's. How many depends on the frame's order of draws (#36: one more
batched pass a frame than I39's runs, holding such a draw).

- records_into_recording: the recording's command buffer, or the open batch's segment while its primary is that command
  buffer (executed there, in the same submission, after the stream is flushed). provoking_list and drawid_indirect ask it;
  a DrawIdDirect record of a draw in a segment is now taken from the stream too, as in the primary, instead of drawn direct
  with MoltenVK's stale draw index.
- provoking_room: the list's room is taken right after the draw's admission (the last place its recording can change, a
  handoff giving a new stream) and before the descriptors' uploads, so provoking_write only writes into it and cannot fail.
  No room there (RX_VK_STREAM_GROW_OFF, or no buffer made): the draw is drawn as it was with its own topology's pipeline
  (waited for, as a segmented variant is), logged and counted as "drawn as they were"; never left out. The tally's lost
  counter and the report's "left out, no room ..." clause go: nothing can count there now.
- Cost: none on the fast path. The list's stream_alloc moved from the draw to after the admission (the same bytes; a draw
  skipped between the two leaves its list's room unused until the recording ends); records_into_recording is cmd == rec_cmd
  first, the batch's state read only for another command buffer.

MoltenVK only (devices without provokingVertexLast; DrawIdDirect on MoltenVK; MeshBatch on MoltenVK). Tests:
tests/test_stream_room.py (new: run #36's frame under 32 switch sets, a stream filled between decision and draw, a handoff
into a stream that cannot hold the list, no memory there, a draw-index draw in a segment; every case fails on 2b4b7b8e),
test_provoking_first, test_drawid_direct (a segments case), test_widen8, test_seg_gathers, test_draw_side_effects updated.

Ported onto topic/mac-perf (StreamRoom's macos/stream-room, I40 2b4b7b8e; its every-platform second commit bbfb465f, the
direct quad draw's needed room, is a PR of its own): tests/seg_gathers_test.cpp's ProvokingFirst stand-ins replaced in
place, before FanIndirect's as the topic has them; test_provoking_first.py's docstring keeps the topic's gate (every device
off macOS counts nothing) with this commit's words; everything else line for line as on 2b4b7b8e.

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
(cherry picked from commit ae7daf5fb708e4185a5d316edee1cd25e73515d9)
StreamRoom (reports/2026-11-15-stream-room.md). ae7daf5f's fallback, a ProvokingFirst draw whose list found no room after the
admission drawn as it was, asks graphics_pipeline() again for the plain variant with the game's topology, inside draw(). The
check that graphics_pipeline() is reached from draw() alone counted two calls; it now counts the three, two of them the plain
variant's. MoltenVK paths only (the fallback runs on devices without provokingVertexLast).

Ported onto topic/mac-perf after ae7daf5f's port (dd801607); line for line as on bbfb465f.

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
(cherry picked from commit d987ab79a8a196ebf0712101c9da19d4886b2418)
On macOS (arm64, and x86_64 under Rosetta) collect_in reads the write marks
64 to a test with inline-asm 16-byte loads (ld1 .16b, movdqu) from any page,
then takes each mark read set in turn with the same relaxed load and acquire
exchange as before. Since the byte loads (a3f3001d8) the walk cost 0.31 ns a
mark there, 4-6 times Linux's word walk: about 0.7 ms of each submit on the
presenting thread (ReplayCPU #2).

The loads are the asm's own, not C accesses, so they race nothing in the C
memory model, and each byte they read is single-copy atomic: the writers'
granule and the byte loads'. Like those relaxed loads they order nothing and
only choose pages: the pages found, their order, the marks cleared and what a
found page's exchange makes visible are the byte walk's. Other systems keep
their walk unchanged (the vector walk is compiled out there).

HOS_COLLECT_VECTOR=0 (read once, logged) is the byte walk on the same build.
test_collect_wide compiles both walks and requires the same pages, order and
marks left on random marks and ranges (near page 0, at the array's end,
overlapping, dense), per arch; test_darwin_guest_memory takes the new code.

Ported onto topic/mac-perf (page-scan 74619b9b was on I40 7092f286, where every
system read the marks with the byte loads). Here the byte loads are macOS's only
(#480: elsewhere main's word loads, marks_clear_256), so:
- host/rx_backend.c: the vector walk goes in macOS's branch of collect_in, the
  byte walk its HOS_COLLECT_VECTOR=0 fallback; its code and its switch's reading
  sit under "defined(__APPLE__) && HOS_MARKS_VECTOR", so Windows and Linux compile
  exactly the walk they did (unifdef -U__APPLE__: the file's tokens unchanged);
- tests/test_collect_wide.py: on macOS the commit's fixture, both walks (the vector
  walk's text cut from its comment to collect_in); elsewhere the topic's fixture as
  it was (one walk against the plain one, the wide step counted through its memcpy);
- docs/development.md: HOS_COLLECT_WIDE's row says macOS's byte walk takes it with
  HOS_COLLECT_VECTOR=0; HOS_COLLECT_VECTOR's row as the commit's, without "as on the
  other systems".

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
(cherry picked from commit 74619b9b3f5553aa7d1ad8bc6384c42e2584a9b7)
In this topic #704's PerfInstr hook (perf_drawn after every counted draw) meets #705's IndirectQuads, whose one
vkCmdDrawIndexedIndirect is a sixth counted site in draw() (restacked, with provoking_note and FanKey's census,
a27f8f47): it gets the hook after the census, in the order the direct quads' site has them (count, census,
perf hook, quad_drawn), as I41's 74da414a. Log-only, off by default (RX_VK_PERF_LINES and the GPU timeline): what is
recorded and drawn does not change. test_perf_lines checks six sites (was five), with FanKey's census line at the
three non-mesh ones and FanIndirect's after it at the common end, exactly one place (I41's eb4d0204 form).

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
The stream-room port (dd801607) brought StreamRoom's fixture from I40, where provoking_list's gate is
"if (dev.provoking_vertex) return {};". In this topic #703 gates it with provoking_first() (a device without
provokingVertexLast, on macOS; every device off macOS asks NVN's last vertex of the device), defined outside the
lines the fixture cuts, so stream_room_test.cpp did not build. The fixture now cuts provoking_first too when the
tree has it (@PROVOKING_FIRST@); a tree without it (--source on I40) builds as before.

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
The page-scan port (cd7dd435) took host/rx_backend.c from marks_clear to host_collect in one piece, as on I40, where
every system read the marks with byte loads. In this topic main's word-load test (marks_clear_256) sits between, in
the #else of macOS's marks_clear (#480), so the piece began inside an #if and did not compile ("#else without #if").
The fixture now takes macOS's marks_clear, the vector walk (its comment to collect_in) and collect_in, each whole.

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
In this topic #702's test_fan_indirect (topic 6) cuts draw()'s indirect block, where #782 (Widen8) asks
widen8_range for a restart-off 8-bit draw's 16-bit bind with the pipeline's last_dyn.restart; its fixture had
neither, so it did not build at the topic's tip (it passes at #702's and #782's Sweep3 heads). It gets I41's stubs
(47f4695b): W8Bind and a widen8_range that widens nowhere, as on every driver but MoltenVK, and a last_dyn with
restart off. The fixture is now I41 78ec1c47's, byte for byte.

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
The owner's decision (2026-11-15): LoadClear, #780's commit 30f0ebec5 here and off
by default since I40, leaves this topic. The E-series measured it at 0.1 ms of GPU
time a frame (E4c against E2), under the 0.17 ms run-to-run noise
(reports/2026-11-15-mac-perf-before-after.md), and only what is measured faster is
adopted.

Removed: gpu/vk/load_clear.h; the pass whose vkCmdBeginRendering is held for its
leading whole clears (pass_settle, draw_pass_held, draw_pass_settle, the replay's
keeps_lead); Targets::whole_extent; the clears' load-op path; vendor fix
load_clear and RX_VK_LOAD_CLEAR; the bench arm load_clear; its start-up line; the
L2 line's count of what each leading whole clear became; the docs' rows;
tests/test_load_clear.py.

begin_pass, the two clears and end_pass are again as #783 (MeshBatch) had them
before it was stacked on LoadClear (macos/mesh-batch 29b93740), and
test_mesh_batch.py and test_widen8.py check that form again (their checks at
29b93740 and macos/widen8 a0e18543). PerfInstr's L2 still counts the leading
whole clears a CLEAR load op would make free (#704's).

Rebased onto main 7bacf846 (conflict with #443, by hand): the held pass's settle leaves replay(); main's part end right
before a plain draw stays.

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
The owner's decision (2026-11-15): Widen8's look ahead, #782's widening of a
pass's 8-bit indices before the pass and off by default since I40, leaves this
topic. The E-series measured it at 0.1 ms of GPU time a frame (E4b against E2),
under the 0.17 ms run-to-run noise (reports/2026-11-15-mac-perf-before-after.md),
because RX_VK_INDEX8_RAW already widens the restart-off draws at the draw; only
what is measured faster is adopted. #782's RX_VK_INDEX8_RAW stays.

Removed: gpu/vk/widen8_scan.h (the scan of the op stream ahead of a pass); the
replay's cursor (replay_cursor, replay_at, replay_end); vendor fix widen8,
dev.widen8 and RX_VK_WIDEN8 with its start-up line; widen8_on and the bench arm
widen8; the ranges widened before a pass in both forms, with their tallies and
census word; the restart form (Push's restart and census fields, widen8::map,
mapped, raw_at, pair_bytes, Range's second offset, Table::has).

Kept, what restart-off 8-bit draws draw unchanged: widen8_before_draw widens a
restart-off draw's indices zero-extended at the draw, its pass ended for it;
widen8_before_pass records that one range between the pass-start barrier and
the pass; widen8_range binds it for that draw and for later draws of the pass
with the same binding until a draw may write memory. The shader widens
zero-extended only; widen8_comp_spv.h is made again from it (glslang 16.6.0,
the command in widen8.comp). The log line counts only the widening at the draw.

Tests: tests/widen8_test.cpp drops the scan, the two forms and the look ahead's
timeline arms and keeps every value, the shader's words and census, the draws,
the table and the timeline with index8_raw on and off; tests/test_widen8.py
checks the widening at the draw and that the look ahead stays gone;
tests/stream_room_test.cpp's matrix loses its look-ahead switch (16 sets);
test_draw_binds.py and test_readback_part.py say what their counted sites are
now. Docs: the RX_VK_WIDEN8 row and the bench arm go; RX_VK_INDEX8_RAW's row
says what the draws bind.

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Rebased onto main 7bacf846, imports_give_back's head carries main's #223 accounting
(`evicted_import_bytes -= ...` before #846's `destroy_import(p)`), and the fixture that
cuts that head out of vk_memory.cpp did not declare it: test_darwin_renderer failed to
compile on both architectures. The fixture now takes the variable's real declaration
from vk_memory.cpp, as it takes the pools' (nothing else changes; the test passes on
arm64 and on x86_64 under Rosetta).

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Rebased onto main 7bacf846, this topic meets main's tests/test_linux_pressure.py (#223),
which cuts the program cache's functions out of vk_progcache.cpp; #644's note of each
stage's OpArrayLength (`spirv_lengths::array_length`) is in those functions now, and the
fixture did not include the header that declares it: the test failed to compile.
tests/linux_pressure_test.cpp includes gpu/vk/spirv_lengths.h beside linux_pressure.h,
as vk_progcache.cpp does; nothing in the test changes (it passes on arm64 and on x86_64
under Rosetta).

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Rebased onto main 7bacf846, a recording's c1 uploads are main's #231 FlatMap keyed by the
stage's address (`FlatMap<uintptr_t, ...> c1_at`, `find(key)`, `[key]`), and two fixtures
of this topic did not build: test_seg_gathers cuts RecordingRes from vk_draw.cpp without
flat_map.h, and seg_bind_test.cpp's own RecordingRes kept the old
`unordered_map<const void*, ...>`. Both builds take `-include gpu/vk/flat_map.h` where the
tree has it (as main's own cut fixtures do), and seg_bind_test.cpp declares c1_at as the
tree does (HAVE_FLAT_C1, read from vk_draw.cpp); a base tree from before #231 builds as
before. Both tests pass on arm64 and on x86_64 under Rosetta.

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Rebased onto main 7bacf846, main's #713 moved the predicted keys' file read, its
`head[0] == program_cache_stamp()` check included, out of predicted_keys() into
predicted_keys_read(), and #701's test_fan_key looked for the check in predicted_keys():
"predicted_keys: not stamped with program_cache_stamp". The test now checks the same text in
predicted_keys_read() where the tree has it (predicted_keys() otherwise); nothing else
changes. Passes on arm64 and on x86_64 under Rosetta.

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Rebased onto main 7bacf846, two of this topic's tests met main's code:
- test_perf_lines looked for PassEnd::PartSplit right before the pass end in maybe_split();
  main's #443 ends a part in split_part() (maybe_split calls it, or a plain draw asks for
  it), where the rebase put the `perf_lines::why(PassEnd::PartSplit)` line. The check
  reads split_part() where the tree has it ("void maybe_split: its pass end is not said
  to be PartSplit right before it" before).
- test_stream_room cuts RecordingRes, whose c1_at is main's #231 FlatMap: its build takes
  `-include gpu/vk/flat_map.h` where the tree has it, as main's cut fixtures do (it did not
  build).
Both pass on arm64 and on x86_64 under Rosetta.

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #650 (#650), branch mac/prep-fast at 6bc44ad83b (Sweep3, on main aa95d35f).

Merged with the topic's earlier commits by hand where they met (Consolidate-files/hand-resolutions.md).

Its own commits, squashed:
- fix(macos): the shader preparation runs on every usable CPU on macOS (928d6afc0)
- fix(macos): a pipeline cache per preparation worker on MoltenVK (71ddd7247)
- fix(macos): the worker caches make no Vulkan call from a header (7b957f8ec)
- fix(macos): MoltenVK starts with an empty pipeline cache and writes none (4c8c82548)
- fix(macos): the worker caches follow main's fetch lock (#190) and Intel's gate (#252) (6bc44ad83)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #651 (#651), branch mac/thread-stack at a7c1f493de (Sweep3, on main aa95d35f).

Its own commits, squashed:
- fix(vk, macos): the renderer's threads start with a 16 MiB stack, not macOS's 512 KiB (16f8f3d2a)
- test(macos): one overflow message from thread_stack_test, however many threads overflow at once (b355d677f)
- test: the checks that compile renderer code with its threads see thread_stack.h (a7c1f493d)

Rebased onto main 7bacf846 (include conflicts with #223 and #769): vk_memory.cpp keeps main's linux_pressure.h and this
commit's thread_stack.h; vk_replay.cpp keeps main's hold_gpu.h and this commit's thread_stack.h.

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #652 (#652), branch mac/precompile-stall at ba5aa17684 (Sweep3, on main aa95d35f).

It was stacked on #650, #651; their changes are the earlier commits here.

Merged with the topic's earlier commits by hand where they met (Consolidate-files/hand-resolutions.md).

Its own commits, squashed:
- fix(vk): MoltenVK: the precompile goes on behind the game; slow compiles named; a failed compile tried once more (5ceb62a44)
- test(vk): test_precompile_handoff: a tree without the change says each missing piece (576970be4)
- docs: RX_VK_PRECOMPILE_STALL_S, RX_VK_COMPILER_SERVICE and RX_VK_SLOW_COMPILE_S (3c8381113)
- fix(vk): name a graphics compile at its precompile callers, not inside build_graphics (fe6efa98d)
- fix(vk): the precompile hand-off on main's Intel gate and quick builds (#252), fetch lock (#190) and game folder (#321) (ba5aa1768)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #664 (#664), branch mac/warm-handoff at 1f7065181d (Sweep3, on main aa95d35f).

It was stacked on #652; their changes are the earlier commits here.

Merged with the topic's earlier commits by hand where they met (Consolidate-files/hand-resolutions.md).

Its own commits, squashed:
- fix(vk): under compiler_service the preparation leaves the compute pipelines to the precompile (22e75176e)
- fix(vk): at most four giant compiles at once in the precompile under compiler_service (748c4970f)
- docs: RX_VK_GIANT_COMPILES and RX_VK_GIANT_WORDS; the preparation's compute pipelines under compiler_service (225b7b0be)
- fix(vk): giant compiles never hold every worker of a phase (23d8d276b)
- test(vk): test_warm_handoff follows main's warm and dispatch (#252, #190) (1f7065181)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #665 (#665), branch mac/title-stall at a7e966ec87 (Sweep3, on main aa95d35f).

It was stacked on #664; their changes are the earlier commits here.

Merged with the topic's earlier commits by hand where they met (Consolidate-files/hand-resolutions.md).

Its own commits, squashed:
- fix(vk): behind the game no giant compile starts before the first frame; the precompile's giants and its work behind the game below the game's QoS class (1e92c87bb)
- docs: RX_VK_GIANT_HOLD_PRESENTS, RX_VK_GIANT_HOLD_S and RX_VK_COMPILE_QOS (5fb67e4fc)
- fix(vk): a giant compile that failed is tried once more alone, not at once among the other giants (a7e966ec8)

Rebased onto main 7bacf846 (include conflict with main's glibc <malloc.h>): vk_draw.cpp keeps main's glibc block and this
commit's Apple <pthread/qos.h> block, each in its own #if.

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #666 (#666), branch mac/loading-stall at 91b67ad468 (Sweep3, on main aa95d35f).

It was stacked on #665; their changes are the earlier commits here.

Merged with the topic's earlier commits by hand where they met (Consolidate-files/hand-resolutions.md).

Its own commits, squashed:
- fix(vk): a dispatch's compute pipeline that MoltenVK's compiler service failed is built, not left out for good (1cb6be613)
- test: test_loading_stall: a tree without the build's retry is a failure said, not a stop (2869b762e)
- perf(vk): RX_VK_SKIP_LOG off works out nothing for a dispatch left out (f9ca934d8)
- fix(vk): a dispatch's build lets play's want go by its own scope, its failed() as it was (daf95bfb7)
- fix(vk): one place, one count and one wording for a failed compile's tries alone (324b0f0fe)
- fix(vk): the dispatch's want and LoadingStall's checks follow main's build (#252) (f0b82bc57)
- test(vk): test_intel_quick_compute reads the dispatch's build with the compile board's capture (91b67ad46)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #667 (#667), branch mac/metal-cache2 at bf988f6226 (Sweep3, on main aa95d35f).

It was stacked on #653, #666; their changes are the earlier commits here.

Its own commits, squashed:
- feat(macos): MoltenVK's pipelines kept in Metal binary archives (6cdd4ddb0)
- fix(macos): the binary archives' state outlives the process's exit (69d3197c6)
- test(macos): test_metal_archive: no -pthread on Windows (eef27adbc)
- fix(macos): Metal binary archives saved once each, by one gated saver, with Metal's staging removed (584acb7a8)
- fix(macos): compile_board has external linkage, for the Metal archive saver in vk_main.cpp (bf988f622)

Comment reworded here (gpu/vk/metal_archive.h's Why, lines 5-10): it states what the runs observed of Metal's
shader cache and no longer cites how Apple's library works.

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #669 (#669), branch mac/giant-mem-gate at 143345156d (Sweep3, on main aa95d35f).

It was stacked on #642, #666; their changes are the earlier commits here.

Its own commits, squashed:
- fix(vk): behind the game, giant compiles wait for memory; a lost device on the Mac is said as one (415eb9a45)
- docs: RX_VK_GIANT_ROOM_MB in the switch table (cb5eef04c)
- fix(macos): the lost wait's line and end on the Mac only; vk_replay.cpp as it was elsewhere (143345156)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #681 (#681), branch mac/metal-scratch at e0400e839c (Sweep3, on main aa95d35f).

It was stacked on #663; their changes are the earlier commits here.

Merged with the topic's earlier commits by hand where they met (Consolidate-files/hand-resolutions.md).

Its own commits, squashed:
- diag(vk): RX_VK_LMEM_LOG names each module's private memory and each pipeline's first bind (0f7820dc3)
- test: the excerpt fixtures know RX_VK_LMEM_LOG's hooks (83ae4962d)
- fix(vk): RX_VK_LMEM_LOG on main's dispatch and program cache: the bound pipeline named, the notes beside array_length (6f4512064)
- fix(macos): RX_VK_LMEM_LOG logs on macOS only (e0400e839)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #784 (#784), branch mac/giant-compile-2 at 99e43bd2f3 (Sweep3, on main aa95d35f).

It was stacked on #669, #681; their changes are the earlier commits here.

Its own commits, squashed:
- fix(vk): SegBind's left-out dispatches named, and the precompile's checks read the renderer's dispatch names, after #669 met #681 (05ab99e91)
- test: test_private_memory looks for note_private_memory after a stage's words, as the program cache notes them once #669 met #681 (c7cca440f)
- fix(vk): heavy compiles run alone under Metal's compiler service; the first giant behind the game no longer waits for 16 GB (8b4538f58)
- fix(vk): the local memory weight lives in private_memory.h, so vk_progcache.cpp's cut-out fixtures build (f4be3d899)
- docs(vk): heavy_weight's comment says what probe GC-02 found (9a4f8a6d0)
- docs: RX_VK_GIANT_ROOM_MB's row says the first giant behind the game starts unless the pressure is critical (a70cb0f37)
- fix(vk): the local memory weight is noted on macOS only, where the precompile reads it (99e43bd2f)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #785 (#785), branch mac/kk-compiler-service at 588d5f3851 (Sweep3, on main aa95d35f).

It was stacked on #665; their changes are the earlier commits here.

Its own commits, squashed:
- fix(macos): KosmicKrisp's compiles go through the compiler service's precompile, as MoltenVK's do (588d5f385)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Was: #786 (#786), branch mac/windowed-metal-cache at 976bb0ac6d (Sweep3, on main aa95d35f).

It was stacked on #654, #667, #686; their changes are the earlier commits here.

Merged with the topic's earlier commits by hand where they met (Consolidate-files/hand-resolutions.md).

Its own commits, squashed:
- fix(macos): Metal's shader cache folder asked at the host's start, before SDL's window (42ae6d37d)
- fix(macos): the Metal cache check is Apple host API 27, after the Rosetta imports' backing generation at 26 (976bb0ac6)

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Run 36 (I40) began one of its eight heavy compiles in a 15-minute hold. Play's dispatch asked for and
began compute 44511d69 (126,010 SPIR-V words, not heavy) at the load into play; it takes about 15
minutes (889 s in run 25, 965.6 s in run 34, the only runs that held it that long), and while it was
wanted and in flight giant-compile-2's alone rule held every heavy compile back (Board::holds, a giant
of play's on the board), and play's want held the 204 deferred giants back too. A run of the
precompile's that never ended would have stopped the whole precompile behind the game (the drain).

Now a compile in flight for RX_VK_STALE_COMPILE_S (240 s; 0: never, as before) no longer counts,
unless it is heavy: a run of the precompile's (by its first item, from when next() gave it), play's
giant compile (Span, from play_begin) and a compile play waits for (by its program, from want). A
heavy compile still never begins beside another heavy one, play's included whatever its age (play's
compile is heavy by the precompile's measure: heavy_program), nor while memory refuses or the hold
lasts; a young compile still keeps it back until it ends. Tries alone keep their rule. The begin line
says what a heavy compile began beside. 240 s: of the 234 non-heavy compiles of 10 s or more that ended
in runs 32 and 34-36 and I39's eight, all but three took at most 182.7 s, one 429.8 s.

MoltenVK and KosmicKrisp only (compiler_service); every other driver as before.
reports/2026-11-15-giant-starve.md.

Ported onto topic/precompile-metal (main aa95d35f's dispatch build, #252): there the build's want is its
first line, ahead of Intel's on_worker returns, and its serial push passes true; the want names its
program at that first line and at the push, as on I40, and test_loading_stall.py checks both.

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
(cherry picked from commit 5292596d69ccf321d0d12f73e39e65753f7ca2be)
Compute 44511d69 (126,010 SPIR-V words, a giant but not heavy) takes about 15 minutes (889 s in run 25,
965.6 s in run 34). In every run read (runs 32 and 34-36, I39's eight, E8a) the precompile claimed it in
its last minutes, among the largest computes or last of the slow list, with four giants in flight: it was
deferred at the giant bound, still deferred at the hand-off, and play's dispatch began it 43-65 s after
the hand-off, at the load into play. Its dispatches were left out for about the first 15 minutes of play
in every start, and no arm64 run held it that long, so Metal's cache never had it.

Now the compute and mesh fallback programs the slow list says took RX_VK_SLOW_FIRST_S (240 s; 0: none)
or more, none heavy, go first in the precompile's order, the longest first, at most the giant limit less
one (slow_first): each compiles beside the rest from the start, at the thread's own QoS class as play's
dispatch asks. Before the game each is a giant like any other: the bound stays four. At the hand-off the
ones still in flight are handed to play (Giants::hand_over): behind the game they keep no place of the
limit and the memory gate does not count them (Giants::counted), as play's own compile of the program was
not counted in every run before; a try alone still waits for them and, while young, a heavy compile
(GiantStarve's rule). Not handed, the slow one would keep every other giant and heavy compile back until
it ends whenever the memory is short of a room, which it was behind the game in runs 32 and 34-36 and E8a.
A first one begun after the hand-off is never handed. behind_worker leaves a run before giving its place
back, and its try alone names its run (solo_ask(at)), so a handed run leaves the counts exactly once.

MoltenVK and KosmicKrisp only (compiler_service); every other driver as before.
reports/2026-11-15-slow-first.md.

Ported onto topic/precompile-metal after giant-starve's port: docs/development.md's RX_VK_COMPILE_QOS row as this
commit words it, followed by the topic's RX_VK_GIANT_ROOM_MB row (#784), which I40 did not have there; every other
change line for line as 40a86bae made it on 5292596d.

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
(cherry picked from commit 40a86baedd6ba1651dc2e62e74af64eccbc18e5c)
The header's comment, two of its code comments and three comments in test_metal_archive.py's fixture
named Apple's internal libraries, functions and return codes (libCoreFSCache, its 0xd3, the archiver's
and packer's internals). They came from reading Apple's binaries, which is not ours to do; they are
reworded to what runs and public notes show (reports/2026-11-15-metal-cache-cap.md):
- the cache: two files capped at about 1 GiB each (public notes), unchanged in size since run #17,
  written by a warm start within a minute of the hand-off at the latest, nothing compiled later kept;
- the staging: one gpuarchiver-* folder per archive, left behind after a save (run #21: 1,042, 12 GB),
  named by the archive and removed by the saver;
- render pipelines without a fragment function: archives of their own, so that a save Metal refuses
  with "expecting 'fragment' stage in pipeline no. N" (run #21) costs none of the others.
No code change: both files are line for line the same without their // comments.

Ported onto topic/precompile-metal: the header's Why (lines 5-10), which #667's commit here already reworded, now
reads as this commit words it; both files are byte for byte 63fc3d2c's.

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
(cherry picked from commit 63fc3d2cecd006a97726f9451c8bdfc4176e83a6)
The giant-starve port (310fbb8e) moved play's want into main's dispatch build (#252), the lambda
"auto build = [job, on_worker, made_how, board_on]", and changed test_loading_stall.py's cut to it;
test_giant_alone.py still cut I40's "auto build = [job, board_on]", which the topic does not have, and
failed with "a function not found". Its cut now names main's build; the checks on what the build holds
(play's giant compile begun, heavy or not, as it begins) are unchanged.

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
In this topic #664's check (test_warm_handoff) meets #695's RX_VK_SPV_PROFILE line in seed_compute (topic 4), as
Integration 25 met them; the check failed at the topic's tip (it passes at #664's Sweep3 head), so this takes I41's fix:

A second semantic merge fix for Integration 25. test_warm_handoff
(WarmHandoff, acd3a71a) checks in vk_shader.cpp's seed_compute that a
kept variant is saved (program_cache_save) on the line before the warm
is given it, by matching the two lines verbatim. SpvSize (1a50b01b)
adds spv_profile_lines before the save on that line and a comment after
it, so on the merged tree the check failed though the order is
unchanged. Each branch passes alone. The check now strips comments and
asks for a line ending in the save, followed by `if (made) made(*t.p);`
(checked: it still fails with the two lines swapped or without the
save).

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
(cherry picked from commit 1cbb594a6ab716a864ef54b327339470f33a0f8b)
Run N3 (2026-11-15, macOS 26.7.1, MoltenVK) never reached Metal's compiler service: 17,946 "Unable to reach
MTLCompilerService … Connection init failed at lookup" lines, every compile failing within milliseconds. LS
read each failure as the program's own: it spent every try alone in about a second, gave 7,932 compute
pipelines up before the game started, and a play build that failed was failed for the session.

precompile_handoff.h ServiceReach judges the service out of reach from the compiles' own results: 8 in a row
(RX_VK_SERVICE_BURST) failing in under 250 ms each (RX_VK_SERVICE_FAST_MS), nothing made between. Then no
compile goes to it but one probe at a time, after 1 s and then twice as long each time (30 s at most); a
compile made, or one that failed slower (the service answered), says it is back.

vk_draw.cpp create_watched asks it before each compile under compiler_service. Out of reach, a compile on the
precompile's workers or the tries alone's thread (service_waits) waits, and the precompile's wait still hands
the game on once nothing has finished for the stall time; on any other thread (the preparation's workers,
play's job workers, the replay) it is not asked (-78), so nothing the title waits for hangs on the service,
and the caller is told (service_skipped). A failure while out of reach is not compiled once more
at once. The tries alone that failed meanwhile are given back (Board::alone_refund); play's compute build and
its retry alone leave the program to be asked for again at its next dispatch instead of failed; a graphics
pipeline's full build is built again once the service answers (graphics_rebuild through service_defer), its
entry staying ready so that no draw waits for the service. The log says the loss and the recovery.

Every other driver, and MoltenVK with the service answering, as before. A run of SPIR-V to MSL conversion
failures looks the same: the probe after 1 s is then made, and the pause has cost that second.

tests/service_reach_test.cpp and tests/test_service_reach.py: the class, Board::alone_refund and the wiring;
tests/test_precompile_handoff.py's compile_again fixture now runs vk_draw.cpp's own service_reach,
service_defer and service_noted with create_watched against the made-up driver's service out of reach and
back. docs/development.md: the two knobs.

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
(cherry picked from commit 5f91a8f7c30b074148deba6806e3057377b73052)
Rebased onto main 7bacf846, main's tests/test_linux_pressure.py (#223) cuts vk_shader.h's
Stage and Program into its fixture, and this topic's Program holds a SegSig (`Program::seg`,
#658) over runtime_info.h's Shader::SegEntry: the fixture failed to compile ("unknown type
name 'SegSig'"). Where vk_shader.h has SegSig, the fixture cuts it too and takes a global
stand-in for SegEntry through `-include`, the one tests/test_program_cache_one_variant.py
uses; on a tree without SegSig nothing changes. Passes on arm64 and on x86_64 under Rosetta.

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Main's tests/test_linux_pressure.py (#223) cuts the program cache's functions out of
vk_progcache.cpp, which on this topic note each module's private memory through
private_memory.h (#651's MetalScratch: `private_memory::scan`, `local_weight`); the fixture
did not include the header and failed to compile. tests/linux_pressure_test.cpp includes
gpu/vk/private_memory.h as vk_progcache.cpp does (no check changed). Passes on arm64 and on
x86_64 under Rosetta.

Assisted-by: Claude Opus 5.5
Co-Authored-By: Claude Opus 5.5 <[email protected]>
The rebase's application of the import-table commit removed struct DarwinImportBacking, struct DarwinImportView and Pool's import_view member while later macOS commits kept using them; the macOS build could not compile vk_memory.cpp. Restored from 9c103916.

Assisted-by: opencode (deepseek-v4.1-flash)
process_start gained the macOS sysctl kern.proc.pid/kern.bootsessionuuid block (lost during the rebase), and Bridge.server_pid now uses macOS's LOCAL_PEERPID (there is no SO_PEERCRED), so a relaunch's follow_relaunch can name the process answering the socket. test_longshot_ctl compares the run folder by realpath for macOS's /tmp link.

Assisted-by: opencode (deepseek-v4.1-flash)
main deleted docs/development.md and keeps switches in docs/dev/reference/switches.md; the branch had re-added it. The macOS compiler-service, Metal cache/archive, mesh batch, worker-cache, LMEM_LOG and slow-compile switch rows move to switches.md, and the tests that read them point there.

Assisted-by: opencode (deepseek-v4.1-flash)
channel.rs's fcntl pre_exec and sys.rs's signal handling are cfg(unix); on macOS the crate had no libc dependency, so longshot-builder (and the tests that run it) failed with E0433. Matches builder-darwin (#9).

Assisted-by: opencode (deepseek-v4.1-flash)
The 16 MiB thread helper moved the renderer's threads to thread_stack::thread, and the cut-out fixtures compile that source: they now include/copy thread_stack.h. test_device_policy drops the removed Widen8 look-ahead and covers the current worker_caches/pcache_no_load/compiler_service fields; test_intel_prepare_side_by_side stubs compiles_watched/create_watched.

Assisted-by: opencode (deepseek-v4.1-flash)
Repairs left by the merge: the parallel replay removal (par_active guards) and its records-keeping flag; the branch's move-only Pool in bg_ready; fan_key's topology_class and a duplicate vertex_bind_reuse; the perf_report function renamed perf_report_line (main's perf_report namespace); the segmented-variant codes_of now SharedCode; create_instance keeps main's Streamline-layer retry and dlssg_layer/without_layer; CLOCK_BOOTTIME and two narrowing casts are macOS-clean. Syntax-checked with the bundled LLVM 23.1.5: vk_draw, vk_memory, vk_main, vk_replay, vk_shader, vk_progcache, vk_texture, vk_programs, vk_framegen all clean.

Assisted-by: opencode (deepseek-v4.1-flash)
test_widen8 no longer expects the parallel-replay par_active guard in gpu_buffer_bind_imported; switches.md's RX_VK_BENCH_AB row drops the removed widen8 bench arm; test_vk_darwin_admission stubs dlssg_instance_layer and includes <atomic> for the ported create_instance.

Assisted-by: opencode (deepseek-v4.1-flash)
test_perf_lines follows main's present_tagged/do_present signatures, the removed parallel replay (record_segment, the probe/perf serial guard), the fo_collect return and perf_wants_sleep_timing. test_mesh_conv's fixture gains main's SegXfer/MeshBatch/perf stand-ins for the cut fallback_record and mesh conversion.

Assisted-by: opencode (deepseek-v4.1-flash)
toolchain: -mcpu=native on arm64 instead of the x86-64 levels; plan: -mcx16 only on x86-64; the lift's opaque-bit empty asm uses arm64's FP/SIMD constraint (w) there; win32_posix: darwin_wait_word for the atomic32 wait/wake; ReShade FX: stdlib/alloca instead of malloc.h on Apple. With the bundled LLVM 23 and the SDK sysroot, dev compile now compiles the renderer and the lifted game IR on arm64.

Still blocked for a full local build: longshot-builder's link and packaging are Linux/Windows only; main's game/cloth_* is SSE-only (__m128/_mm_*, no arm64 path); the host source set compiles Linux-only files (host/posix/prof.c) on macOS. Those are the #966 builder port and an arm64 cloth path, not configuration.

Assisted-by: opencode (deepseek-v4.1-flash)
The rebase onto main put the tree on main's Rust builder, which was Linux/Windows only while the #966 work built on the old nx2 Python path. This ports it:
- Target model: Settings/Toolchain carry macos+arch (host / RX_TARGET / RX_ARCH); macOS native target (-arch, -mmacosx-version-min=14.4, -isysroot SDK), ld64.lld/ld, -mcpu=native (arm64), and Rust's aarch64-apple-darwin staticlib.
- Compile plan: Darwin host sources (shared fault/fiber/mem/process/wait plus the host's darwin_* set, never prof.c), the renderer's own Darwin subset, no -D_GNU_SOURCE, FFmpeg/SDL from LONGSHOT_FFMPEG/LONGSHOT_SDL2, XeSS and ReShade's share.h Windows-only, and main's SSE-only cloth excluded on non-x86_64 (game/oot_cloth.c stubs the site callbacks; x86_64 unchanged).
- Link: Mach-O executable and longshot_vk.dylib (dynamiclib, @loader_path/@rpath, -dead_strip, -undefined error, exported _hos_posix_*); LLVM 23's libc++/libc++abi beside it, with the host preloading them before Vulkan so the renderer keeps its compiled-against runtime; SDL/MoltenVK/loader packaged beside the game.
- Host fixes main's later code needed on macOS: hos_relaunch's keep_env/start_stderr, mkw_glue's host_statistics64, hos_sdl's audio_open declaration, an unterminated #endif in hos_crash_record.c.
- sim_turf settings: plain char path on Unix, C file I/O, and its saved config gated off on macOS (the parser still traps under the mixed C++ runtime; the page uses defaults).
Verified: dev build makes a native arm64 folder that launches, loads MoltenVK, creates a device, reports the GPU and renders offscreen. Remaining runtime: a preparation worker throws std::runtime_error("a network left out on this card") and terminates (the pre-rebase build does the same here). 52/53 build-compile unit tests pass; the one needs lld-link (Windows).

Assisted-by: opencode (deepseek-v4.1-flash)
The macOS game loads the system's older libc++ while the renderer is built
with the newer one; main's new perf-report and sim-turf paths use std
streams there, and the mixed runtime traps in ifstream/filebuf on the
first present. Read the perf-report switch and the sim-turf settings with C
file I/O on Apple, skip the sim-turf settings load, and stop a host-side
libc++ preload. Return from the renderer's "network left out" path instead
of throwing from inside the shader worker, where the exception could
escape the worker frame.

Assisted-by: opencode (deepseek-v4.1-flash)
build(macos): stop shipping a second libc++ with the renderer
Some checks failed
PR description / Title and description (pull_request_target) Successful in 11s
CI / What the change needs (pull_request) Has been cancelled
CI / Lint (pre-commit, ShellCheck, actionlint) (pull_request) Has been cancelled
CI / Third-party parts and guide screenshots (pull_request) Has been cancelled
CI / Rust (rustfmt, clippy, cargo test, end to end) (pull_request) Has been cancelled
CI / Host C for Windows (llvm-mingw, compile only) (pull_request) Has been cancelled
CI / Renderer build check (Windows, compile --only renderer, without and with FSR 4) (pull_request) Has been cancelled
CI / Renderer build check (Linux, compile --only renderer, without and with FSR 4) (pull_request) Has been cancelled
CI / Game-free checks (run_all.py, part 1/2) (pull_request) Has been cancelled
CI / Game-free checks (run_all.py, part 2/2) (pull_request) Has been cancelled
CI / Website build and checks (pull_request) Has been cancelled
feda916095
The game's other dylibs pull Apple's libc++ first, so the copy placed
beside the renderer could not give it a single runtime there, and the
first-start stream paths now read and write with C file I/O. Let the
renderer's @rpath libc++ resolve to the system's copy again.

Assisted-by: opencode (deepseek-v4.1-flash)
Member

Possibly related, for context:

  • issue #420 Idea: a native macOS build (Apple silicon, x86-64 under Rosetta) with Vulkan on Metal through MoltenVK — Open tracking issue for the native macOS build being implemented.
  • issue #432 Idea: guest-memory fixes from the macOS port on Windows and Linux too, once timed (dirty-page atomics, zeroed pages marked, fatal allocation failures) — Tracks cross-platform guest-memory changes and qualification relevant to this port.
Possibly related, for context: - issue #420 Idea: a native macOS build (Apple silicon, x86-64 under Rosetta) with Vulkan on Metal through MoltenVK — Open tracking issue for the native macOS build being implemented. - issue #432 Idea: guest-memory fixes from the macOS port on Windows and Linux too, once timed (dirty-page atomics, zeroed pages marked, fatal allocation failures) — Tracks cross-platform guest-memory changes and qualification relevant to this port.
DuckNintendo closed this pull request 2026-11-29 20:01:02 +00:00
DuckNintendo changed title from feat(macos): add a macOS build to WIP: feat(macos): add a macOS build 2026-11-29 20:01:42 +00:00
DuckNintendo reopened this pull request 2026-11-29 20:01:43 +00:00
Bring the macOS port onto current main. Conflicts are resolved by keeping
main's simulated-turf, keyboard-policy and pause-in-background work beside
the branch's macOS host, builder and renderer paths; the old sim-turf
settings page gives way to main's actor-turf page.

Assisted-by: opencode (deepseek-v4.1-flash)
test(macos): match the merged replay signature and host ABI
Some checks failed
PR description / Title and description (pull_request_target) Successful in 9s
CI / What the change needs (pull_request) Has been cancelled
CI / Lint (pre-commit, ShellCheck, actionlint) (pull_request) Has been cancelled
CI / Third-party parts and guide screenshots (pull_request) Has been cancelled
CI / Rust (rustfmt, clippy, cargo test, end to end) (pull_request) Has been cancelled
CI / Host C for Windows (llvm-mingw, compile only) (pull_request) Has been cancelled
CI / Renderer build check (Windows, compile --only renderer, without and with FSR 4) (pull_request) Has been cancelled
CI / Renderer build check (Linux, compile --only renderer, without and with FSR 4) (pull_request) Has been cancelled
CI / Game-free checks (run_all.py, part 1/2) (pull_request) Has been cancelled
CI / Game-free checks (run_all.py, part 2/2) (pull_request) Has been cancelled
CI / Website build and checks (pull_request) Has been cancelled
87085985e0
The merged renderer's replay takes the turf snapshot, and the host ABI is
57 with two more pointers. Drop the nx2-only macOS build-flags test (its
a64-kit toolchain file is not in this tree).

Assisted-by: opencode (deepseek-v4.1-flash)
fix(macos): close the merged dispatch and keep the bench hash parameter
Some checks are pending
CI / What the change needs (pull_request) Blocked by required conditions
CI / Lint (pre-commit, ShellCheck, actionlint) (pull_request) Blocked by required conditions
CI / Third-party parts and guide screenshots (pull_request) Blocked by required conditions
CI / Rust (rustfmt, clippy, cargo test, end to end) (pull_request) Blocked by required conditions
CI / Host C for Windows (llvm-mingw, compile only) (pull_request) Blocked by required conditions
CI / Renderer build check (Windows, compile --only renderer, without and with FSR 4) (pull_request) Blocked by required conditions
CI / Renderer build check (Linux, compile --only renderer, without and with FSR 4) (pull_request) Blocked by required conditions
CI / Game-free checks (run_all.py, part 1/2) (pull_request) Blocked by required conditions
CI / Game-free checks (run_all.py, part 2/2) (pull_request) Blocked by required conditions
CI / Website build and checks (pull_request) Blocked by required conditions
PR description / Title and description (pull_request_target) Successful in 11s
3f987efdb9
The merged dispatch lost its closing brace where main's simulated-turf
code met the branch's, and the merged bench replay needs the optional
hash texture the macOS benchmark passes.

Assisted-by: opencode (deepseek-v4.1-flash)
First-time contributor

Hey there @DuckNintendo , I've been following the original macos PR by mooki and I noticed this one is now fresher. I have some bandwidth that I can spend helping, but I don't want to end up with redundant work. What's the latest on this PR? Is it just black screen-ing after the intro video or is there some new progress from the original macos PR? Thanks!

Hey there @DuckNintendo , I've been following the original macos PR by mooki and I noticed this one is now fresher. I have some bandwidth that I can spend helping, but I don't want to end up with redundant work. What's the latest on this PR? Is it just black screen-ing after the intro video or is there some new progress from the original macos PR? Thanks!
Some checks are pending
CI / What the change needs (pull_request) Blocked by required conditions
CI / Lint (pre-commit, ShellCheck, actionlint) (pull_request) Blocked by required conditions
CI / Third-party parts and guide screenshots (pull_request) Blocked by required conditions
CI / Rust (rustfmt, clippy, cargo test, end to end) (pull_request) Blocked by required conditions
CI / Host C for Windows (llvm-mingw, compile only) (pull_request) Blocked by required conditions
CI / Renderer build check (Windows, compile --only renderer, without and with FSR 4) (pull_request) Blocked by required conditions
CI / Renderer build check (Linux, compile --only renderer, without and with FSR 4) (pull_request) Blocked by required conditions
CI / Game-free checks (run_all.py, part 1/2) (pull_request) Blocked by required conditions
CI / Game-free checks (run_all.py, part 2/2) (pull_request) Blocked by required conditions
CI / Website build and checks (pull_request) Blocked by required conditions
PR description / Title and description (pull_request_target) Successful in 11s
This pull request has changes conflicting with the target branch.
  • builder/crates/build-compile/src/host_sources_tests.rs
  • builder/crates/build-compile/src/lib.rs
  • builder/crates/build-compile/src/packages.rs
  • builder/crates/build-compile/src/plan.rs
  • builder/crates/build-compile/src/toolchain.rs
  • builder/crates/build-core/Cargo.toml
  • builder/crates/build-driver/src/build.rs
  • builder/crates/longshot-builder/src/from_source/mod.rs
  • docs/dev/reference/switches.md
  • game/discord_rpc.c
  • game/oot_cloth.c
  • game/oot_tools.c
  • gpu/vk/device_policy.h
  • gpu/vk/eden/shader_recompiler/backend/spirv/emit_spirv_mesh.cpp
  • gpu/vk/menu/crt.cpp
  • gpu/vk/menu/pipeline_list.cpp
  • gpu/vk/menu_module.h
  • gpu/vk/perf_report.cpp
  • gpu/vk/vk_api.h
  • gpu/vk/vk_bug_report.cpp
  • gpu/vk/vk_draw.cpp
  • gpu/vk/vk_draw.h
  • gpu/vk/vk_internal.h
  • gpu/vk/vk_main.cpp
  • gpu/vk/vk_memory.cpp
  • gpu/vk/vk_menu.cpp
  • gpu/vk/vk_progcache.cpp
  • gpu/vk/vk_recorder.h
  • gpu/vk/vk_replay.cpp
  • gpu/vk/vk_shader.cpp
  • gpu/vk/vk_shader.h
  • gpu/vk/vk_temporal.cpp
  • gpu/vk/vk_texture.cpp
  • gpu/vk/vk_vma.cpp
  • gpu/vk/vk_work.h
  • host/control.c
  • host/hos.h
  • host/hos_crash_record.c
  • host/hos_main.c
  • host/hos_relaunch.c
  • host/hos_relaunch.h
  • host/hos_sdl.h
  • host/hos_thread.c
  • host/posix/win32_posix.c
  • host/rx_backend.c
  • scripts/longshot_bridge.py
  • tests/control_test.c
  • tests/crash_record_test.c
  • tests/display_startup_failure_test.cpp
  • tests/fsr_uniform_ownership_test.cpp
  • tests/present_source_crop_test.cpp
  • tests/recording_admission_test.cpp
  • tests/sampler_admission_test.cpp
  • tests/test_amd_subgroup_profiles.py
  • tests/test_control.py
  • tests/test_crash_record.py
  • tests/test_debug_tools_linux.py
  • tests/test_device_policy.py
  • tests/test_direct_buffer_writes.py
  • tests/test_draw_side_effects.py
  • tests/test_fallback_depth_hold.py
  • tests/test_fps_stats.py
  • tests/test_fsr_image_retirement.py
  • tests/test_image_reaper_threads.py
  • tests/test_import_reach.py
  • tests/test_linux_pressure.py
  • tests/test_longshot_ctl.py
  • tests/test_oot_state_tap.py
  • tests/test_pipeline_share.py
  • tests/test_program_cache_cleanup.py
  • tests/test_program_cache_one_variant.py
  • tests/test_vendor_fixes.py
Some workflows are waiting to be reviewed.
View command line instructions

Manual merge helper

Use this merge commit message when completing the merge manually.

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u 'macos/rebase-966:DuckNintendo-macos/rebase-966'
git switch 'DuckNintendo-macos/rebase-966'
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
3 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
MagicBeanDev/Longshot!2816
No description provided.