onnxruntime
73e0a4b3 - [WebGPU] allow WGSL template generation (#25130)

Commit
166 days ago
[WebGPU] allow WGSL template generation (#25130) ### Description This PR introduces the [WGSL-Template](https://github.com/fs-eire/wgsl-template) into WebGPU EP to enable the capability of template based WGSL source generation. The purpose of this change is to improve the readability of the WGSL source code and reduce the future maintenance cost due to the difficulty of understanding the current WGSL code generation logic. ### Explanation - build - for static code generator: `--use_webgpu` - for dynamic code generator: `--use_webgpu --use_wgsl_template dynamic` - the template files use extension `.wgsl.template` and are located in `core/providers/webgpu/` folder. - the corresponding C++ file should use `shader_helper.ApplyTemplate<...>()` to apply the template. (check pad.cc for example) - for documentation - https://github.com/fs-eire/wgsl-template --------- Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Author
Parents
Loading