metal: Emit MSL powr for WGSL pow builtin MSL pow() is different from WGSL/GLSL pow() in that it allows negative base values and is presumably more expensive as a result. MSL `powr` is closer to the WGSL/GLSL definition of `pow`. In WGSL spec, `pow` is defined as `Inherited from exp2(y * log2(x))` and `log2(e)` is not "mathematically meaningful" for `e < 0`. Further, this expectation of disallowing `x < 0` via validation is in WebGPU CTS already in `webgpu/shader/validation/expression/call/builtin/pow` Bug: 347282475 Change-Id: I589255b3211db0e64cc333ca9f13639112d10847 Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/194200 Reviewed-by: dan sinclair <dsinclair@chromium.org> Auto-Submit: Sunny Sachanandani <sunnyps@chromium.org> Commit-Queue: Sunny Sachanandani <sunnyps@chromium.org>
Dawn is an open-source and cross-platform implementation of the WebGPU standard. More precisely it implements webgpu.h that is a one-to-one mapping with the WebGPU IDL. Dawn is meant to be integrated as part of a larger system and is the underlying implementation of WebGPU in Chromium.
Dawn provides several WebGPU building blocks:
webgpu.h version that Dawn implements.webgpu.h.Helpful links:
Developer documentation:
User documentation: (TODO, figure out what overlaps with the webgpu.h docs)
BSD 3-Clause License, please see LICENSE.
This is not an officially supported Google product.