Files
metal2vulkan/docs
Anees Iqbal a950689934 Extended shadows go: no variant reads and writes an extended-range attachment's half shadow
Metal's tile memory holds an extended-range color attachment (BGR10_XR, BGRA10_XR,
RGB10A8_2P_XR10 and their sRGB twins) as half through a render pass and rounds it to the codes
only at the store. The binder offered a variant for a draw whose render pass instance held a
half shadow of such an attachment (BindState/BindShape::extended_shadows,
VariantKey::extended_shadows, LoweringInputs::extended_shadows). Its fragment function read and
wrote an Rgba16f storage image beside the codes (ResourceKind::ExtendedShadow), either in the
interlocked storage form or, on a device that fetches through rasterization-order input
attachments, beside the input attachment (lower::fragment's input_shadow). metal2vulkan-runtime
never asks for the variant and makes no extended-range texture (Gap::TextureFormat), so nothing
reached it.

Now no such variant exists. A function compiled with no shadow (every function, as before for
every rt draw) is unchanged: a blend or fetch onto an earlier draw's write reads the codes that
draw stored (extended_range::tile_value). Those differ from Metal's half where it is not a code's
value, and fetch's module docs say so.

Removed:
- lowering: lower/fragment/input_shadow.rs (InputShadow and its plan, read, store and words),
  FragmentPlan::input_shadows, Declared::extended_shadows, the storage form's shadow
  (StorageColor::shadowed, declare_shadow, shadow_and_texel, shadow_read, the shadowed branches of
  texel, value, the write and its blended and merged forms, and their word estimates), and the
  input-attachment blend's, color read's and stage_io write's shadow branches. The loop over
  covered samples no longer has a shadow refusal. The blend's doc, which sat above
  merged_extended, now sits on blended.
- pipeline: LoweringInputs::extended_shadows and its key bytes, VariantKey::extended_shadows,
  ResourceKind::ExtendedShadow, BindingSource::ExtendedShadow and its link arm, the fetch inputs'
  shadowed reads and writes and their tests and coverage (the input-attachment form passes no
  depth, stencil or coverage state, as before for an unshadowed draw), and the requirements
  trace's ExtendedShadow arm. MovableStorageWrites' doc loses the shadow.
- binder: BindState::extended_shadows, BindShape::extended_shadows, WriteSource::ExtendedShadow,
  and the graphics binder's choice of the shadowed variant (its refusals of a mesh, layered,
  amplified or multisampled plain writer's shadow included).
- tests: engine_fragment's four shadow tests and their helpers (image_accesses,
  shadow_image_types, execution_modes, interlocked); engine_moved_writers' shadow move (its Move
  enum goes, and the writers are checked with the interlocked move alone); the shape round-trip,
  the variant round-trip fixtures, the compile-key test's shadow arm, and the requirements test's
  ExtendedShadow kind.

No SEMANTICS_VERSION bump: an input without shadows (every input a consumer can now state)
lowers to the same words. Removing the shadowed branches leaves the instruction order of the
unshadowed paths as it was, and the key appended shadow bytes only when the set was non-empty.
ARTIFACT_FORMAT_VERSION 569 (after guestgaps' 568 on 81bd82fdaa): the codec loses
ResourceKind::ExtendedShadow and BindingSource::ExtendedShadow. RUNTIME_VERSION stays: no run of
an unchanged artifact and plan does anything else, since no consumer set the field, so this
commit updates the runtime pin alone. api_signatures is regenerated, and so is docs/REFUSALS.md
(FramebufferFetch: 18 sites to 15).

Consumer check (consumer-uses.sh, consumer development b955213d27, 64 refs; on development 81bd82fdaa): extended_shadows,
ExtendedShadow, InputShadow, input_shadow: 0 hits (code).

Verified: nothing yet; the two fix-forward commits after this one make it build (60740, 60749),
and the check job of the series is named with the refusal commit.
2026-11-20 17:26:22 -08:00
..