webonnx / wonnx

A WebGPU-accelerated ONNX inference run-time written 100% in Rust, ready for native and the web
Other
1.61k stars 59 forks source link

fix: use read_write access mode for variables in 'storage' address #121

Closed pixelspark closed 2 years ago

pixelspark commented 2 years ago

This replaces var<storage, write> in shader code with var<storage, read_write>. This is required because write is not supported (anymore?) for variables in the storage address space, but read_write is. In particular the Google Chrome (Tint) compiler complains about this. For more information see https://www.w3.org/TR/WGSL/#address-space.

This PR makes the Squeeze WebAssembly demo work again. See https://pixelspark.nl/wp-content/public/squeeze/