3.265. __nv_normf
-
float @__nv_normf(i32 %dim, float const* %a)
Calculate the square root of the sum of squares of any number of coordinates.
Calculate the length of a vector p, dimension of which is passed as an argument
withoutundue overflow or underflow.Note
For accuracy information, see the CUDA C++ Programming Guide, Mathematical Functions Appendix, Single-Precision Floating-Point Functions section.
- Returns
Returns the length of the dim-D vector \(\sqrt{\sum_{i=1}^{dim} p_i^2}\). If the correct value would overflow, returns \(+\infty\). If the correct value would underflow, returns 0. If two of the input arguments is 0, returns remaining argument