Files
metal2vulkan/docs
Anees Iqbal f683293b4b Docs: a fetch may read the texel from before its draw, so overlapping read-modify-writes leave one
UnorderedFetchWithinDraw's words said a pixel that overlapping fragments of one draw fetch and
write "holds the result of some order of the draw's fragments", "not necessarily Metal's". The
Radeon 780M (RADV, Mesa 26.2.6) shows otherwise. Job m3-max-83259 ran the eight authored cases
the ordered_fetch_within_draw gap holds (n instances of the companion's fullscreen triangle in
one draw, so n identical fragments at every pixel or sample) five times at 702916d9d3. All five
outputs were identical. Every differing word is the fragment function applied once to the
texel as it stood before the draw. Each case's chain f^k(initial), computed from its own inputs,
gives Metal's stored output at k = n on every word, and the 780M's at k = 1 on every word that
differs, all four lanes of each texel alike. All n fragments are identical, so every order of
them gives Metal's value: the 780M's value is no order's result. Lavapipe matches Metal on the
seven cases it runs (job m3-max-83255).

The note now says what a fetch can observe there: it may read the texel from before its draw,
so overlapping read-modify-writes of one draw may leave one application. Changed in docs/API.md's
precision-note catalogue, PrecisionNote::UnorderedFetchWithinDraw's doc comment and the runtime
README's known gap. Docs only, no behaviour change. The runtime-sources pin is unchanged
(pin-compute.py gives a92fe0a8...).

Verified: cargo fmt --all; nothing built.
2026-12-03 03:35:47 -08:00
..