The kernel a WebGPU member runs, and everything such a member needs that is not the device, under the existing quantum_fabric feature with no new dependency; it builds and is tested on every target including wasm32-wasip2. - lanes32.wgsl: quantum_fabric::lanes transcribed line for line into WGSL, every value a u32 holding a 32-bit pattern, with an exact 64-bit copy of every result so that the kernel reports, exactly, any result that leaves 32 bits. No signed type, float, division, conversion, workgroup memory or barrier; every shift amount a literal. Entry points apply (one gate, one invocation per amplitude pair, in place) and probe (the wide multiply and the exact fx on listed operands). - quantum_fabric::wgsl: SHADER, the implementation id (BLAKE3 over the shader text and HOST_LAYOUT), the 64-byte gate record, the dispatch grid (X_GROUPS_MAX = 64, so 2-D grids occur from 14 qubits, inside fabric-v1), AdapterIdentity with its member id (local/gpu-... or local/swgpu-..., both sorting after every local/cpu-<arch>) and CI key, and the seven textual mutants with their detectors. The module docs carry the argument that the kernel is bit-exact (same function, exact fx64, no dynamic error, order independence). - .gitattributes: the shader is checked out with LF, since its bytes are hashed. - wai/tools/quantum-wgsl-check (unpublished, own lockfile; the only place naga is a dependency): parses and validates SHADER under naga 30.0.1, walks the IR (entry points, bindings, no workgroup variable, bool/u32 scalars only, no conversion/division/math, literal shifts in 1..=31, atomicOr/atomicMin only, no barrier), translates to MSL 2.4, SPIR-V and HLSL 5.1, writes lanes32.spv for spirv-val, and checks every mutant validates. --shader <file> checks another text, to show a planted violation failing. Pinned: implementation wgsl-lanes32/dc8e19f61e0e87ab; member ids of the two test identities local/gpu-metal-a47619e299a8 and local/swgpu-vulkan-917c9bb1d948 (each cross-checked by an independent BLAKE3 computation). The probe mutants' witness counts over the probe edges equal the ones computed when the mutants were chosen. Co-Authored-By: Claude Opus 5.5 <[email protected]>
3 lines
183 B
Text
3 lines
183 B
Text
# The shader's bytes are hashed into its implementation id (quantum_fabric::wgsl):
|
|
# a checkout that converted line endings would change the id.
|
|
src/quantum_fabric/*.wgsl text eol=lf
|