One work packet, landed as 5 commits (8ec20af606..60fe70fb12 on archive/development-linear-2026-10-28), in order:
* Keep the samples a resolve after the pass reads on a framebuffer-fetch-by-input device
A multisampled color attachment resolved by the crate-owned resolve after the pass
(the sRGB twin, an extended-range format) under `MultisampleResolve` is meant to
render through an image its texture keeps, so the texture keeps the samples it held
before the pass, as Metal's does (`resolve::keep_samples`). The pass asked it whether
a draw took a view of the attachment with the linear rule's `taken`, which on a device
whose framebuffer fetch reads input attachments (`PassLayout::fetch_inputs`:
rasterizationOrderColorAttachmentAccess, lavapipe's) counts every color of every pass.
So on such a device no pass ever kept its samples: the attachment held the resolving
pass's clear and draw (lavapipe: `80808080` where Metal keeps `bf4080ff`; BGRA10_XR
`c09f...` where Metal keeps its earlier clear).
keep_samples now takes `viewed`, the colors a draw actually read (input attachment,
pixel interlock, sample planes, another format's view, the extended-range shadow), as
`kept_bytes::settle` asks it of the attachment it renders apart. The subpass's input
references name the framebuffer's attachments, which take the kept image's view, and a
stand-in takes input attachment usage on such a device (`attachment_stand_in.rs`), so
nothing a draw recorded refers to the attachment's own image. The linear rule keeps
`taken`.
RUNTIME_VERSION 1700 (to be renumbered at landing).
Verified: runtime_lane::resolves::samples_a_twin_resolve_reads_are_kept_as_metal_keeps_them
and ::samples_an_extended_range_resolve_reads_are_kept_as_metal_keeps_them failed on
arm64 lavapipe at 742b94ac06 (diagnostic print: every pass's color counted taken,
`fetch_inputs` true, including a pass with no draw) and pass with this change; both pass
on MoltenVK (M3 Max), where `fetch_inputs` is false and nothing changes.
* Wait on the GPU for the signal a checked head's shared-event wait is held for
Since 0f374bc9ec a shared event's wait is held on the host until its value is reached
and never handed to a VkQueue: `EventTimeline::wait` answers `None` for a settable
event's unreached value even where a submitted GPU signal reaches it. The scheduler
found the indices it may wait for on the GPU through that same answer (`check_heads`'s
`event_waits`, `gpu_waits`'s `WaitFor::Index`), so a checked head waiting for a shared
event recorded nothing to wait for, and the scheduler's thread slept on its condition
variable for the completion turns on every driver but MoltenVK's alike, where its
contract (scheduler/mod.rs, "Waits for a signal to land itself") is to wait in one
vkWaitSemaphores for the signal itself.
`EventTimeline::landing` answers how the host waits for a value: reached, or the index
of the submitted signal that reaches it, whether or not the host may set it; `wait` is
`landing` less a settable event's index. The scheduler's head checks
(`landing_waits`) and its GPU wait take `landing`, so the thread waits on the GPU for a
held wait's signal as for a plain event's; a host set still wakes it through the nudge.
No batch is handed a held index: submissions still go by `wait`.
The runtime behaviour change rides RUNTIME_VERSION 1700 with the resolve change before it.
Verified: runtime_lane::event_round_trips::a_checked_head_waits_for_another_queue_s_signal_on_the_gpu
and ::a_host_signal_wakes_the_scheduler_from_its_wait_on_the_gpu failed on arm64
lavapipe at 742b94ac06 (diagnostic print: the checked head's event wait `None` after the
signalling batch was submitted, then reached; no GPU wait; the second test timed out at
60 s) and pass with this change (WorkCounts::scheduler_gpu_waits above zero, the host
signal waking it; the second in 5 s); both pass on MoltenVK, which keeps its condition
variable (`WaitForAnyObjectLosesASignal`). New device-free test
host_settable_event_waits::a_held_wait_lands_where_a_plain_event_s_wait_chains.
* Ask the layer whether it sees a kernel's write before a sync lane needs one
Four runtime_lane::sync_coverage controls and parity::sequences::lane's hazard control
expected the validation layer's synchronization checks to report a hazard whose earlier
access is a kernel's write of a bound buffer. Since ca74ea24d4 every store through a
descriptor view on a device with variable pointers is an `OpSelect` of the slot's place
and the stage's store sink (`lower::access::sink`), and the layer does not trace a store
through a selected pointer to its descriptor: it takes the kernel's every bound buffer as
read alone. Measured with a dispatch of hand-assembled modules on the runtime's device,
then a copy with no barrier: the store through an access chain is reported
(SYNC-HAZARD-READ-AFTER-WRITE), the same store through the select is not, with Ubuntu
26.04's layer 1.4.341 on arm64 lavapipe and with Homebrew's 1.4.363 on MoltenVK (M3 Max)
alike. So the layer's version is not the cause, and the runtime's recording is not
either: it orders nothing between the two accesses, as Metal leaves them to the program.
As the owner decided for a layer blind to kernel writes: the lanes ask the layer first,
by capability, never by its version. The positive control is
`a_shader_write_then_a_copy_of_one_untracked_buffer`'s run (one dispatch writing an
untracked buffer through the runtime's recording, then a copy, nothing else), done once a
process (`layer_sees_kernel_writes`). Where it finds the layer blind, each test whose
hazard needs a kernel's write prints one `LAYER-BLIND-KERNEL-WRITES <test>: ...` line
naming what it did not check, and requires the layer to have reported nothing of the rest
of its run (`blind_to_kernel_writes`; disjoint_words still checks its bytes). Where the
layer sees the write, every assertion stands as before. docs/VALIDATION.md and the lane's
LaneChecks docs say so.
Verified: the five failed on arm64 lavapipe at 742b94ac06 and pass with this change, each
printing its marker; on MoltenVK (layer 1.4.363) they pass and print the marker as well,
the control there reporting no hazard either.
* Number RUNTIME_VERSION 1670, after development's 1669
The branch's placeholder 1700 left a gap; the resolve and shared-event GPU-wait fixes
take the next number after development's.
* Re-pin the runtime sources at the landing tip
The landed packet changed a runtime-sources input, so the committed digest no
longer described the sources and `the_runtime_sources_are_the_committed_ones`
would fail. Recomputed over the same inputs and committed by land-pkt.sh.