Translator: SparseResidency's text names a footprint of the border alone

PrecisionNote::SparseResidency said the device's OpImageSparse* residency may count a texel of
zero weight Metal does not. Public case fd292944c2 (a 256x128 r32_float sparse texture with x
128-255 mapped) found a second way the device's word differs: lavapipe answers not resident for
a clamp_to_border access whose footprint is the border alone (nearest at u -0.5 and 1.5, linear
at u -0.5, -1/256 and -1/512, gather at u -0.5 and 1.5), where Metal answers resident, beside a
mapped edge too. Every value word was equal; 7 of 200 residency words differ (valexec2's proof
m3-max-61595, decoded against the committed Metal rows). Vulkan states only "whether any texels
accessed by the instruction are sparse unbound texels" (vkspec 20.2.6), so the word is the
device's, which the note's first clause already says; its text now names this case beside the
zero-weight texel, in the doc comment and in docs/API.md's catalogue.

Doc only: no emission, key or version change.
This commit is contained in:
Anees Iqbal committed 2026-11-20 21:37:51 -08:00
1 parent 55e5dcfd98
commit bcc417bc08
2 files changed
+7 -2

No files matched your search

+5 -1
View File
@@ -809,7 +809,11 @@ pub enum PrecisionNote {
/// lacks, through the texture's swizzle) are set after every access (`SpecKey::ConstantLanes`);
/// none of them is noted. A sample's or gather's residency is the device's, noted: the word is
/// the device's `OpImageSparse*` residency, whose footprint may count a texel of zero weight
/// Metal does not (Vulkan's linear 2x2 footprint does, measured on lavapipe), and its lanes
/// Metal does not (Vulkan's linear 2x2 footprint does, measured on lavapipe), and may call a
/// footprint of the border alone (a `clamp_to_border` access wholly outside the texture)
/// not resident where Metal answers resident (lavapipe does, by nearest, linear and gather
/// sampling, beside a mapped edge too; Vulkan states only whether a texel accessed is a sparse
/// unbound texel), and its lanes
/// that are no constants over a texel in a block of a sparse image that holds no mapped tile
/// are the device's non-resident value (zero on a device with `residencyNonResidentStrict`;
/// any value elsewhere, which the runtime announces as `non-strict-residency`). Where the
+2 -1
View File
@@ -2120,7 +2120,8 @@ bound.
samples or gathers a texture whose residency it observes (`sparse_color::resident`) through the
slot's sparse form, which the module has where the profile enables `shaderResourceResidency`:
the word is the device's `OpImageSparse*` residency, whose footprint may count a texel of zero
weight Metal does not, and an unmapped texel's lanes the device's non-resident value. Where the
weight Metal does not or call a footprint of the border alone not resident where Metal answers
resident, and an unmapped texel's lanes the device's non-resident value. Where the
device has no residency of its own, the slot's tile map answers Metal's footprint rule exactly,
unrecorded.
- `metal2vulkan-degrade-device-nan-encoding` (precision). `PrecisionNote::DeviceNanEncoding`: A