Two authored workloads with CPU references, for timing two encodings the workaround ladder makes
unconditional:
- narrow_ints (narrow_mix): 2^19 threads, 512 steps each of 8- and 16-bit arithmetic. The
translation holds each value in a 32-bit container and clears the bits above its width after
every step that can set them, so the mask's encoding (OpBitwiseAnd or OpBitFieldUExtract) is on
the loop's critical path. The reference is Rust's wrapping arithmetic, word for word.
- zero_products (signed_zero_products): 2^19 threads, 512 steps each multiplying a float4 by the
function constants +0.0 and -0.0 in one block beside an FMA, in precise arithmetic
(`#pragma METAL fp math_mode(safe)`, which leaves the products without fast-math flags, so no
compiler may fold them). The products' sum is a zero, so the result is the FMA chain's, held
to a tolerance of 1e-4.
workloads.ll and workloads.air.ll regenerated with scripts/regen-air-fixtures --dir harness on
the M3 (job m3-max-41406, same toolchain as TOOLCHAIN records).