Files
metal2vulkan/docs
Anees Iqbal 671140cc3c Pipeline creation log: a compute line names its required subgroup size and why its simdgroups are emulated
METAL2VULKAN_LOG_PIPELINES's compute lines (the making line before the driver's call and the
made line after it) now also name:

- the subgroup size the VkPipeline is created to require: `subgroup size required 32`, or
  `subgroup size any` where it requires none (the ComputeStage's required_subgroup_size, the value
  the runtime hands VkPipelineShaderStageRequiredSubgroupSizeCreateInfo);
- why the kernel emulates its simdgroups, where the runtime can tell: `simdgroups emulated (widest
  pin)` where the translator's census holds simd.emulated.widest-pin (the emulation in place of
  the pin to the device's widest mode), `simdgroups emulated (variant)` where the dispatch's
  variant is the emulated-simdgroups one (VariantKey::emulated_simdgroups), else `simdgroups not
  emulated for the widest pin or a variant`. The last is worded so because the runtime does not
  see the translator's tier: the device's subgroup model and the lockstep order choose the
  emulated tier too, and telling them apart would need a translator change.

Why: to read off a creation's own line whether a slow driver compile (a kernel that took 49 s on
ANV) was the widest pin's emulation, without a counter. Default-off, diagnostics only; the
translator is unchanged (env_vars.rs's description of the variable is the one line there).
WIDEST_PIN_STRATEGY in pipeline/sources.rs is shared with the log rather than spelled twice.

Docs: docs/API.md's paragraph on the log and the variable's description in env_vars.rs.

Verified (job m3-max-25986, msi, 60327894c6): cargo clippy -p metal2vulkan -p metal2vulkan-runtime
--all-targets --all-features -D warnings, exit 0; under --cfg m2v_cpu_icd, clippy of the runtime
exit 0 and tests::opencl_data::the_pipeline_creation_log_names_a_compute_pipeline_and_its_notes
on lavapipe passed, which now asserts both lines carry `], subgroup size ` and
`simdgroups not emulated for the widest pin or a variant` (vsh_round has no simdgroup
semantics), with the creation_log unit tests (6 run, 6 passed).
2026-11-13 10:23:51 -08:00
..