onnxruntime
dafbea65 - Fix WebGPU DequantizeLinear scalar/vector shader cache collisions (#33122)

Commit
40 days ago
Fix WebGPU DequantizeLinear scalar/vector shader cache collisions (#33122) ### Description Fix a DequantizeLinear shader-cache collision between scalar and vec4 output paths. Packed int8/uint8 inputs use the same storage type in both paths, and the output rank alone does not distinguish the generated shaders. Include the output type/component count in the cache metadata. Add four WebGPU-only regressions covering int8/uint8 and FP32/FP16, with both node insertion orders and CPU fallback disabled. ### Motivation and Context QDQ propagation inserts a scalar-output DequantizeLinear after Reshape in the reported model. A later vector-output operation can reuse that scalar shader and produce incorrect values. This fixes the cache identity without changing QDQ propagation or quantization arithmetic. Fixes #32931. ### Validation - Fresh Windows D3D12 build: 213 quantization tests passed, 4 expected DirectML skips, 0 failures. - All four new regressions fail on the unfixed kernel and pass with this change. - The issue attachment matches CPU and QDQ-disabled WebGPU exactly for three seeds after the fix, including the reported 128.0-error seed. Profiling confirms the affected DQ nodes execute on WebGPU. - Clang-format, lintrunner, and `git diff --check` passed. Metal and browser/WASM were not tested. Explicit Vulkan selection found no available adapter.
Author
Parents
Loading