Files
metal2vulkan/scripts
Anees Iqbal e734db4be2 Runtime: the translator's description states every feature and extension device creation enables that it names; maintenance4 joins the floor
What: shader_enables, the enable set the translator's description of the device is restricted to
(DeviceDescription::with_enabled), now reads every table of features device creation enables
(floor::ENABLED: the floor, the portability subset, the optional features, the attachment
reads, step rates, min-LOD clamps, fill modes, quad control, the pixel interlock, barycentrics,
the border swizzle, linear attachments, fault reports, and the indirect commands' features, now a
table of their own, INDIRECT_COMMAND_FEATURES, which indirect_commands sets). Each entry the
translator names reaches it where creation enabled it. Entries that were enabled but unnamed now
carry the translator's name: depthBiasClamp, drawIndirectFirstInstance, bresenhamLines and
occlusionQueryPrecise (floor), attachmentFeedbackLoopLayout (the attachment reads),
borderColorSwizzle and borderColorSwizzleFromImage, and maintenance5 (indirect commands).
shader_extension names the extensions those need, and the others creation enables that the
translator names: VK_EXT_line_rasterization, VK_EXT_attachment_feedback_loop_layout,
VK_EXT_border_color_swizzle, VK_EXT_custom_border_color, VK_EXT_external_memory_host and
VK_KHR_maintenance5.

maintenance4 joins the floor (REQUIRED, the README's floor table, runtime-floor.json's
m2v_runtime_floor block and regen_device_profiles.py's RUNTIME_FLOOR): Vulkan 1.3 requires it
of every device, so no device at the floor lacks it. The translator's profile reads it for
spirv-val's --allow-localsizeid alone.

Why: the planner's feature-enable walk (lane texoff, 11-21) found these features enabled at
vkCreateDevice and absent from the translator's profile, the class maintenance8 was in before
38dcc857dd. None changes what the runtime does on its own paths: the runtime sets depth bias,
border colors and indirect draws itself, and the translator's readers of these features
(metal::state::depth_bias, the bind plan's indirect_first_instance_missing, metal::sampler's
opaque-black border) are not on them. The profile now states what the device has. Its fingerprint
moves on every device, and with it every cache key.

64-bit image atomics stay off, and the features the translator reads that the runtime does not
enable are the feature-enable test's (next commit).
2026-11-21 13:39:50 -08:00
..