Translator: drop LeafCaps::zero_initialize_workgroup_memory and a dead anisotropy test
Two pieces of dead code go (rule 4). LeafCaps::zero_initialize_workgroup_memory was set from the shaderZeroInitializeWorkgroupMemory query in device::derive and read nowhere. Lowering and the verifier read the enabled feature set instead (lower/access/local.rs, spirv/verify/rules.rs), so no answer changes. The field is not public: device::profile is pub(crate) and LeafCaps is not re-exported. A git grep of the consumer's checkout at eadc8b4a0d finds 0 hits for the field or LeafCaps. The profile's fingerprint is a hash of the fields' Debug text, so every profile's fingerprint moves with this commit. Cache keys miss once and recompute; there is no false hit, so no SEMANTICS_VERSION bump. The golden table goes stale by key alone and re-blesses at the next pin: at this tree 28,860 cells (1,924 rows x 15 profiles) are "under a changed profile", with 0 new, 0 gone, 0 under a changed fixture source and none changed under an unchanged key. Stored observations name the field in their environment/profile Debug text: 12 shard files, 55 lines (4 under observations/refusals/vulkan, 8 under observations/vulkan). They are left as stored; their text already differs from today's profile shape. lower::sampler::anisotropic::select returns as soon as the profile has samplerAnisotropy, so its later `if anisotropy && !reached` test could never be true. It goes with its comment. Behaviour is unchanged on every profile. runtime-sources.sha256 takes the runtime inputs' new hash. derive.rs and profile.rs are inputs, and this change alters no behaviour of a run. The hash also covers two earlier comment-only edits to inputs that left the guard red on development:b07b697aac(device/metal.rs) and7be9f00a3f(device/policy.rs, device/profile.rs). Their .rs diffs change comment lines alone. At7be9f00a3fthe guard test fails and names 5aa066e0..., against the pinned 36ba0695... (job m3-max-82683). Verified on the CPU with no device: - m3-max-82633, the gate at 2523fe20c6 (this change before the hash update): signatures, clippy (plain, m2v_gpu, m2v_cpu_icd), rustdoc and private rustdoc of metal2vulkan all exit 0; conformance 1051/1051; doctests 0. Product suites: 3734 of 3735 passed, 24 skipped; the failure was golden_hashes (stale, above). Validation: 1321 of 1322 passed, 3 skipped; the failure was the runtime guard, which this hash fixes. - m3-max-82683 at 413a1db3f9 (this tree): the runtime guard passes; golden_hashes is stale by profile key alone (above). With the four files at7be9f00a3f: the guard fails (development's red), and golden_hashes passes (1,924 rows x 15 profiles match). - rustfmt --check on the three .rs files.
This commit is contained in:
1 parent
16ce2c2070
commit
a4491c1436
4 files changed
+1
-8
No files matched your search
@@ -1 +1 @@
|
||||
36ba0695b8e3ec9769d8ae2adc34452177fed1e74058f3249c56df524aa224b7
|
||||
f89d23dd11dbb9cf4394b2da7a41f7f6301ad1757ed4313b02370cae0671c089
|
||||
@@ -189,7 +189,6 @@ fn derive_fields(desc: &DeviceDescription, policy: &DevicePolicy) -> ProfileFiel
|
||||
shared_int64_atomics: has(VkFeature::ShaderSharedInt64Atomics),
|
||||
vertex_stores_and_atomics: has(VkFeature::VertexPipelineStoresAndAtomics),
|
||||
fragment_stores_and_atomics: has(VkFeature::FragmentStoresAndAtomics),
|
||||
zero_initialize_workgroup_memory: has(VkFeature::ShaderZeroInitializeWorkgroupMemory),
|
||||
};
|
||||
let images = ImageCaps {
|
||||
storage_read_without_format: has(VkFeature::ShaderStorageImageReadWithoutFormat),
|
||||
|
||||
@@ -536,7 +536,6 @@ pub struct LeafCaps {
|
||||
pub shared_int64_atomics: bool,
|
||||
pub vertex_stores_and_atomics: bool,
|
||||
pub fragment_stores_and_atomics: bool,
|
||||
pub zero_initialize_workgroup_memory: bool,
|
||||
}
|
||||
|
||||
/// Image and sampler capabilities ([`DeviceProfile::images`]). Each field without its own note is
|
||||
|
||||
@@ -322,11 +322,6 @@ pub(super) fn select(
|
||||
&& !other_class
|
||||
&& !swizzled
|
||||
&& matches!(image, ImageRef::Slot(_));
|
||||
// Out of reach, the device's filter, at the footprint the cube's form hands it
|
||||
// (`PrecisionNote::CubeGradientFootprint`).
|
||||
if anisotropy && !reached {
|
||||
return Ok(None);
|
||||
}
|
||||
let note = match reached {
|
||||
true => PrecisionNote::AnisotropicFilter,
|
||||
false => PrecisionNote::DeviceAnisotropicFilter,
|
||||
|
||||
Reference in new issue
Block a user