mirror of
https://github.com/gfx-rs/wgpu.git
synced 2024-11-22 14:55:05 +00:00
feat(const_eval): impl. inverseSqrt
This commit is contained in:
parent
19f5e4d5e4
commit
fc04518750
@ -76,6 +76,7 @@ Bottom level categories:
|
||||
- `exp2`
|
||||
- `floor`
|
||||
- `fma`
|
||||
- `inverseSqrt`
|
||||
- Eager release of GPU resources comes from device.trackers. By @bradwerth in [#5075](https://github.com/gfx-rs/wgpu/pull/5075)
|
||||
- `wgpu-types`'s `trace` and `replay` features have been replaced by the `serde` feature. By @KirmesBude in [#5149](https://github.com/gfx-rs/wgpu/pull/5149)
|
||||
- `wgpu-core`'s `serial-pass` feature has been removed. Use `serde` instead. By @KirmesBude in [#5149](https://github.com/gfx-rs/wgpu/pull/5149)
|
||||
|
@ -924,6 +924,9 @@ impl<'a> ConstantEvaluator<'a> {
|
||||
|e1, e2, e3| { Ok([e1.mul_add(e2, e3)]) }
|
||||
)
|
||||
}
|
||||
crate::MathFunction::InverseSqrt => {
|
||||
component_wise_float!(self, span, [arg], |e| { Ok([1. / e.sqrt()]) })
|
||||
}
|
||||
crate::MathFunction::Round => {
|
||||
// TODO: Use `f{32,64}.round_ties_even()` when available on stable. This polyfill
|
||||
// is shamelessly [~~stolen from~~ inspired by `ndarray-image`][polyfill source],
|
||||
|
Loading…
Reference in New Issue
Block a user